fix: generic fixes after anypay (#3543)

* fix android CI * feat: add anypay core models, parser and routing engine * feat: add anypay resolver, anypay service and wallet switch service * refactor: route the send page payment flow through anypay service * fix: show message when there's no swap providers for a pair and reset the trade guard on dismissal * refactor: merge the swap from network and send to network decision pages together and clean up anypay widgets * feat: reapply deep links to a currently open send flow and register the solana scheme * feat: add support for zcash address detection to anypay and other minor fixes * refactor: remove trailing icon * feat: hide swap flow for sp and mweb addresses * feat: enhance zcash address detection and deeplink handling * fix: pin bitcoin_base * refactor: Move the anypay decision navigation out of the send page and address minor review comments * refactor: Move the anypay decision navigation out of the send page and address minor review comments * feat: handle exception in switch service and mvoe balance compute to call site * refactor: combine anypay entry points to one and extract selected mode widget * fix: tx priority for doge * chore: add dogecoin to isElectrumWallet util * fix: annoying mobx error --------- Co-authored-by: Czarek Nakamoto <cyjan@mrcyjanek.net>

David Adegoke committed Aug 22, 2026 at 13:10 UTC 419d8cdeb478b161cab329bdfcad4cca8f65f987
5 files changed +33 -9
lib/entities/preferences_key.dart
+2 -1
@@ -63,7 +63,8 @@ class PreferencesKey {
63 static const zanoTransactionPriority = 'current_fee_priority_zano';
64 static const wowneroTransactionPriority = 'current_fee_priority_wownero';
65 static const decredTransactionPriority = 'current_fee_priority_decred';
66 - static const zcashTransactionPriority = 'current_fee_priority_decred';
66 + static const zcashTransactionPriority = 'current_fee_priority_zcash';
67 + static const dogecoinTransactionPriority = 'current_fee_priority_dogecoin';
68 static const customBitcoinFeeRate = 'custom_electrum_fee_rate';
69 static const silentPaymentsCardDisplay = 'silentPaymentsCardDisplay';
70 static const mwebCardDisplay = 'mwebCardDisplay';
lib/new-ui/pages/send_page.dart
+7 -6
@@ -215,12 +215,7 @@ class _NewSendPageState extends State<NewSendPage> {
215 final _addressFocusNode = FocusNode();
216 final _disposers = <ReactionDisposer>[];
217 StreamSubscription<Uri>? _deepLinkSubscription;
218 - late final AnyPayFlow _anyPayFlow = AnyPayFlow(
219 - anyPayService: widget.anyPayService,
220 - sendViewModel: widget.sendViewModel,
221 - authService: widget.authService,
222 - walletSwitcherViewModel: widget.walletSwitcherViewModel,
223 - );
218 + late final AnyPayFlow _anyPayFlow;
219 ContactRecord? newContactAddress;
220
221 bool _justHandledPasteButton = false;
@@ -228,6 +223,12 @@ class _NewSendPageState extends State<NewSendPage> {
223 @override
224 void initState() {
225 super.initState();
226 + _anyPayFlow = AnyPayFlow(
227 + anyPayService: widget.anyPayService,
228 + sendViewModel: widget.sendViewModel,
229 + authService: widget.authService,
230 + walletSwitcherViewModel: widget.walletSwitcherViewModel,
231 + );
232 _addInputControllers();
233
234 _disposers.add(
lib/reactions/wallet_utils.dart
+1
@@ -32,6 +32,7 @@ bool isElectrumWallet(WalletType walletType) {
32 case WalletType.bitcoin:
33 case WalletType.litecoin:
34 case WalletType.bitcoinCash:
35 + case WalletType.dogecoin:
36 return true;
37 default:
38 return false;
lib/store/settings_store.dart
+20
@@ -5,6 +5,7 @@ import 'dart:io';
5 import 'package:cake_wallet/bitcoin/bitcoin.dart';
6 import 'package:cake_wallet/core/utilities.dart';
7 import 'package:cake_wallet/decred/decred.dart';
8 +import 'package:cake_wallet/dogecoin/dogecoin.dart';
9 import 'package:cake_wallet/bitcoin_cash/bitcoin_cash.dart';
10 import 'package:cake_wallet/core/secure_storage.dart';
11 import 'package:cake_wallet/di.dart';
@@ -168,6 +169,7 @@ abstract class SettingsStoreBase with Store {
169 TransactionPriority? initialZanoTransactionPriority,
170 TransactionPriority? initialDecredTransactionPriority,
171 TransactionPriority? initialZcashTransactionPriority,
172 + TransactionPriority? initialDogecoinTransactionPriority,
173 Country? initialCakePayCountry})
174 : nodes = ObservableMap<WalletType, Node>.of(nodes),
175 powNodes = ObservableMap<WalletType, Node>.of(powNodes),
@@ -273,6 +275,9 @@ abstract class SettingsStoreBase with Store {
275 if (initialZcashTransactionPriority != null) {
276 priority[WalletType.zcash] = initialZcashTransactionPriority;
277 }
278 + if (initialDogecoinTransactionPriority != null) {
279 + priority[WalletType.dogecoin] = initialDogecoinTransactionPriority;
280 + }
281
282 if (initialCakePayCountry != null) {
283 selectedCakePayCountry = initialCakePayCountry;
@@ -345,6 +350,9 @@ abstract class SettingsStoreBase with Store {
350 case WalletType.zcash:
351 key = PreferencesKey.zcashTransactionPriority;
352 break;
353 + case WalletType.dogecoin:
354 + key = PreferencesKey.dogecoinTransactionPriority;
355 + break;
356 default:
357 key = null;
358 }
@@ -1194,6 +1202,7 @@ abstract class SettingsStoreBase with Store {
1202 TransactionPriority? zanoTransactionPriority;
1203 TransactionPriority? decredTransactionPriority;
1204 TransactionPriority? zcashTransactionPriority;
1205 + TransactionPriority? dogecoinTransactionPriority;
1206
1207 if (sharedPreferences.getInt(PreferencesKey.havenTransactionPriority) != null) {
1208 havenTransactionPriority = monero?.deserializeMoneroTransactionPriority(
@@ -1241,6 +1250,10 @@ abstract class SettingsStoreBase with Store {
1250 zcashTransactionPriority = zcash?.deserializeZcashTransactionPriority(
1251 raw: sharedPreferences.getInt(PreferencesKey.zcashTransactionPriority)!);
1252 }
1253 + if (sharedPreferences.getInt(PreferencesKey.dogecoinTransactionPriority) != null) {
1254 + dogecoinTransactionPriority = dogecoin?.deserializeDogeCoinTransactionPriority(
1255 + sharedPreferences.getInt(PreferencesKey.dogecoinTransactionPriority)!);
1256 + }
1257
1258 moneroTransactionPriority ??= monero?.getDefaultTransactionPriority();
1259 bitcoinTransactionPriority ??= bitcoin?.getMediumTransactionPriority();
@@ -1256,6 +1269,7 @@ abstract class SettingsStoreBase with Store {
1269 bscTransactionPriority ??= evm?.getDefaultTransactionPriority();
1270 zanoTransactionPriority ??= zano?.getDefaultTransactionPriority();
1271 zcashTransactionPriority ??= zcash?.getDefaultTransactionPriority();
1272 + dogecoinTransactionPriority ??= dogecoin?.getDefaultTransactionPriority();
1273
1274 final currentBalanceDisplayMode = BalanceDisplayMode.deserialize(
1275 raw: sharedPreferences.getInt(PreferencesKey.currentBalanceDisplayModeKey)!);
@@ -1744,6 +1758,7 @@ abstract class SettingsStoreBase with Store {
1758 initialBitcoinCashTransactionPriority: bitcoinCashTransactionPriority,
1759 initialDecredTransactionPriority: decredTransactionPriority,
1760 initialZcashTransactionPriority: zcashTransactionPriority,
1761 + initialDogecoinTransactionPriority: dogecoinTransactionPriority,
1762 initialShouldRequireTOTP2FAForAccessingWallet: shouldRequireTOTP2FAForAccessingWallet,
1763 initialShouldRequireTOTP2FAForSendsToContact: shouldRequireTOTP2FAForSendsToContact,
1764 initialShouldRequireTOTP2FAForSendsToNonContact: shouldRequireTOTP2FAForSendsToNonContact,
@@ -1847,6 +1862,11 @@ abstract class SettingsStoreBase with Store {
1862 priority[WalletType.zcash] = zcash!.deserializeZcashTransactionPriority(
1863 raw: sharedPreferences.getInt(PreferencesKey.zcashTransactionPriority)!);
1864 }
1865 + if (dogecoin != null &&
1866 + sharedPreferences.getInt(PreferencesKey.dogecoinTransactionPriority) != null) {
1867 + priority[WalletType.dogecoin] = dogecoin!.deserializeDogeCoinTransactionPriority(
1868 + sharedPreferences.getInt(PreferencesKey.dogecoinTransactionPriority)!);
1869 + }
1870
1871 final generateSubaddresses =
1872 sharedPreferences.getInt(PreferencesKey.autoGenerateSubaddressStatusKey);
lib/view_model/send/send_view_model.dart
+3 -2
@@ -167,9 +167,10 @@ abstract class SendViewModelBase extends WalletChangeListenerViewModel with Stor
167
168 bool get isEVMWallet => isEVMCompatibleChain(walletType);
169
170 - @action
170 CryptoCurrency _outputCryptoCurrencyHandler([CryptoCurrency? override]) {
172 - if (override != null && override != selectedCryptoCurrency) selectedCryptoCurrency = override;
171 + if (override != null && override != selectedCryptoCurrency) {
172 + runInAction(() => selectedCryptoCurrency = override);
173 + }
174
175 return selectedCryptoCurrency;
176 }