From 33bf35e3c4fdaed6e6b0d598efaa3f8f0406c266 Mon Sep 17 00:00:00 2001 From: Craig Raw Date: Thu, 9 May 2024 12:19:19 +0200 Subject: [PATCH] add functions to support qr encoding selection --- .../drongo/wallet/WalletModel.java | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/main/java/com/sparrowwallet/drongo/wallet/WalletModel.java b/src/main/java/com/sparrowwallet/drongo/wallet/WalletModel.java index 963575e..4f1e5d1 100644 --- a/src/main/java/com/sparrowwallet/drongo/wallet/WalletModel.java +++ b/src/main/java/com/sparrowwallet/drongo/wallet/WalletModel.java @@ -115,6 +115,30 @@ public enum WalletModel { } } + public boolean showLegacyQR() { + if(this == COBO_VAULT) { + return true; + } else { + return false; + } + } + + public boolean showBbqr() { + if(this == COLDCARD || this == SPARROW) { + return true; + } else { + return false; + } + } + + public boolean selectBbqr() { + if(this == COLDCARD) { + return true; + } else { + return false; + } + } + public static WalletModel fromType(String type) { for(WalletModel model : values()) { if(model.getType().equalsIgnoreCase(type)) {