diff --git a/DashWallet.xcodeproj/project.pbxproj b/DashWallet.xcodeproj/project.pbxproj index 80181beda..d1a3c3edb 100644 --- a/DashWallet.xcodeproj/project.pbxproj +++ b/DashWallet.xcodeproj/project.pbxproj @@ -386,7 +386,7 @@ 474C7218298A422500475CA6 /* TransactionItemView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 474C7217298A422400475CA6 /* TransactionItemView.swift */; }; 474C721A298A803200475CA6 /* TxListTableViewCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 474C7219298A803200475CA6 /* TxListTableViewCell.swift */; }; 474C721D298B65C100475CA6 /* Cells.swift in Sources */ = {isa = PBXBuildFile; fileRef = 474C721C298B65C100475CA6 /* Cells.swift */; }; - 4751136C28D9A3DB00223B77 /* PortalViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751136B28D9A3DB00223B77 /* PortalViewController.swift */; }; + 4751136C28D9A3DB00223B77 /* BuySellPortalViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751136B28D9A3DB00223B77 /* BuySellPortalViewController.swift */; }; 4751136F28D9B50E00223B77 /* CoinbaseInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751136E28D9B50E00223B77 /* CoinbaseInfoViewController.swift */; }; 4751137528DAF28800223B77 /* UIAssembly.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751137428DAF28800223B77 /* UIAssembly.swift */; }; 4751CAC0296EFD2900F63AC4 /* AccountListController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751CABF296EFD2900F63AC4 /* AccountListController.swift */; }; @@ -407,7 +407,7 @@ 4774DCDD28F43A68008CF87D /* ServiceDataSource.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCDC28F43A68008CF87D /* ServiceDataSource.swift */; }; 4774DCDF28F43AB4008CF87D /* ServiceItem.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCDE28F43AB4008CF87D /* ServiceItem.swift */; }; 4774DCE128F44BA4008CF87D /* ServiceDataProvider.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCE028F44BA3008CF87D /* ServiceDataProvider.swift */; }; - 4774DCE528F4668B008CF87D /* PortalServiceItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCE428F4668B008CF87D /* PortalServiceItemCell.swift */; }; + 4774DCE528F4668B008CF87D /* BuySellServiceItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCE428F4668B008CF87D /* BuySellServiceItemCell.swift */; }; 477A963E292CD27D0013605B /* NetworkUnavailableView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 477A963D292CD27D0013605B /* NetworkUnavailableView.swift */; }; 477F50102950A55A003C7508 /* Coinbase+Error.swift in Sources */ = {isa = PBXBuildFile; fileRef = 477F500F2950A55A003C7508 /* Coinbase+Error.swift */; }; 477F501529531C07003C7508 /* ViewModel+Coinbase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 477F501429531C07003C7508 /* ViewModel+Coinbase.swift */; }; @@ -426,7 +426,7 @@ 4789D22F2981067C00BAFEFA /* UpholdAmountModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4789D22E2981067600BAFEFA /* UpholdAmountModel.swift */; }; 4789D2312981069700BAFEFA /* UpholdTransferViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4789D2302981069700BAFEFA /* UpholdTransferViewController.swift */; }; 4789D27029825F5400BAFEFA /* CoinbaseAmountViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4789D26F29825F5400BAFEFA /* CoinbaseAmountViewController.swift */; }; - 478A2C7128DC554200AD1420 /* PortalModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A2C7028DC554200AD1420 /* PortalModel.swift */; }; + 478A2C7128DC554200AD1420 /* BuySellPortalModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A2C7028DC554200AD1420 /* BuySellPortalModel.swift */; }; 478A2C7228DC909C00AD1420 /* BaseNavigationController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A2C6E28DC457000AD1420 /* BaseNavigationController.swift */; }; 478A9297299242EC0008C43E /* CNCreateAccountTxDetailsModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A9296299242EC0008C43E /* CNCreateAccountTxDetailsModel.swift */; }; 478C98262942DC2700FAA0F0 /* BuyDashViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478C98252942DC2700FAA0F0 /* BuyDashViewController.swift */; }; @@ -906,7 +906,7 @@ C9D2C6AC2A320AA000D15901 /* PayableViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = C9F42F9E29DA82E5001BC549 /* PayableViewController.swift */; }; C9D2C6AD2A320AA000D15901 /* HairlineView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47AE8C1428C6378E00490F5E /* HairlineView.swift */; }; C9D2C6AE2A320AA000D15901 /* DWInitialViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A913E9423A3F75F006A2A59 /* DWInitialViewController.m */; }; - C9D2C6AF2A320AA000D15901 /* PortalViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751136B28D9A3DB00223B77 /* PortalViewController.swift */; }; + C9D2C6AF2A320AA000D15901 /* BuySellPortalViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751136B28D9A3DB00223B77 /* BuySellPortalViewController.swift */; }; C9D2C6B02A320AA000D15901 /* DWSettingsMenuViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A7A7BD52348CB6600451078 /* DWSettingsMenuViewController.m */; }; C9D2C6B12A320AA000D15901 /* AboutViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47AE8C1D28C7491C00490F5E /* AboutViewController.swift */; }; C9D2C6B22A320AA000D15901 /* UISpringTimingParameters+DWInit.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A0C69D92314727F001B8C90 /* UISpringTimingParameters+DWInit.m */; }; @@ -1120,7 +1120,7 @@ C9D2C7A52A320AA000D15901 /* DWModalPresentationController.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A0C69C523142AA4001B8C90 /* DWModalPresentationController.m */; }; C9D2C7A62A320AA000D15901 /* PointOfUseInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47AE8C1028C5430300490F5E /* PointOfUseInfoViewController.swift */; }; C9D2C7A72A320AA000D15901 /* ActionButtonViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47C661B328FDCF7800028A8D /* ActionButtonViewController.swift */; }; - C9D2C7A82A320AA000D15901 /* PortalServiceItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCE428F4668B008CF87D /* PortalServiceItemCell.swift */; }; + C9D2C7A82A320AA000D15901 /* BuySellServiceItemCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4774DCE428F4668B008CF87D /* BuySellServiceItemCell.swift */; }; C9D2C7AA2A320AA000D15901 /* (null) in Sources */ = {isa = PBXBuildFile; }; C9D2C7AB2A320AA000D15901 /* DWBaseFormTableViewCell.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A7A7BC82347E0D700451078 /* DWBaseFormTableViewCell.m */; }; C9D2C7AC2A320AA000D15901 /* AccountCell.swift in Sources */ = {isa = PBXBuildFile; fileRef = 4751CAC6296FAEBB00F63AC4 /* AccountCell.swift */; }; @@ -1146,7 +1146,7 @@ C9D2C7C42A320AA000D15901 /* CurrencyExchanger_Objc.m in Sources */ = {isa = PBXBuildFile; fileRef = 472D13EC299E6579006903F1 /* CurrencyExchanger_Objc.m */; }; C9D2C7C52A320AA000D15901 /* GiftCardInfoViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 47AE8C0D28C540C100490F5E /* GiftCardInfoViewController.swift */; }; C9D2C7C62A320AA000D15901 /* Tools.swift in Sources */ = {isa = PBXBuildFile; fileRef = 471DD1B7290A92CD00E030C8 /* Tools.swift */; }; - C9D2C7C72A320AA000D15901 /* PortalModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A2C7028DC554200AD1420 /* PortalModel.swift */; }; + C9D2C7C72A320AA000D15901 /* BuySellPortalModel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478A2C7028DC554200AD1420 /* BuySellPortalModel.swift */; }; C9D2C7C92A320AA000D15901 /* BuyDashViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 478C98252942DC2700FAA0F0 /* BuyDashViewController.swift */; }; C9D2C7CA2A320AA000D15901 /* DWModalDismissalAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = 2A0C69CF23143435001B8C90 /* DWModalDismissalAnimation.m */; }; C9D2C7CB2A320AA000D15901 /* (null) in Sources */ = {isa = PBXBuildFile; }; @@ -2236,7 +2236,7 @@ 474C7217298A422400475CA6 /* TransactionItemView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TransactionItemView.swift; sourceTree = ""; }; 474C7219298A803200475CA6 /* TxListTableViewCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TxListTableViewCell.swift; sourceTree = ""; }; 474C721C298B65C100475CA6 /* Cells.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Cells.swift; sourceTree = ""; }; - 4751136B28D9A3DB00223B77 /* PortalViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PortalViewController.swift; sourceTree = ""; }; + 4751136B28D9A3DB00223B77 /* BuySellPortalViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BuySellPortalViewController.swift; sourceTree = ""; }; 4751136E28D9B50E00223B77 /* CoinbaseInfoViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CoinbaseInfoViewController.swift; sourceTree = ""; }; 4751137428DAF28800223B77 /* UIAssembly.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = UIAssembly.swift; sourceTree = ""; }; 4751CABF296EFD2900F63AC4 /* AccountListController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AccountListController.swift; sourceTree = ""; }; @@ -2257,7 +2257,7 @@ 4774DCDC28F43A68008CF87D /* ServiceDataSource.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceDataSource.swift; sourceTree = ""; }; 4774DCDE28F43AB4008CF87D /* ServiceItem.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceItem.swift; sourceTree = ""; }; 4774DCE028F44BA3008CF87D /* ServiceDataProvider.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ServiceDataProvider.swift; sourceTree = ""; }; - 4774DCE428F4668B008CF87D /* PortalServiceItemCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PortalServiceItemCell.swift; sourceTree = ""; }; + 4774DCE428F4668B008CF87D /* BuySellServiceItemCell.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BuySellServiceItemCell.swift; sourceTree = ""; }; 477A963A292BA4B90013605B /* uk */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = uk; path = uk.lproj/Interface.strings; sourceTree = ""; }; 477A963B292BA4B90013605B /* uk */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = uk; path = uk.lproj/Localizable.strings; sourceTree = ""; }; 477A963C292BA4B90013605B /* uk */ = {isa = PBXFileReference; lastKnownFileType = text.plist.stringsdict; name = uk; path = uk.lproj/Localizable.stringsdict; sourceTree = ""; }; @@ -2281,7 +2281,7 @@ 4789D23629811FA600BAFEFA /* DWUpholdOTPProvider.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DWUpholdOTPProvider.h; sourceTree = ""; }; 4789D26F29825F5400BAFEFA /* CoinbaseAmountViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CoinbaseAmountViewController.swift; sourceTree = ""; }; 478A2C6E28DC457000AD1420 /* BaseNavigationController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseNavigationController.swift; sourceTree = ""; }; - 478A2C7028DC554200AD1420 /* PortalModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PortalModel.swift; sourceTree = ""; }; + 478A2C7028DC554200AD1420 /* BuySellPortalModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BuySellPortalModel.swift; sourceTree = ""; }; 478A9296299242EC0008C43E /* CNCreateAccountTxDetailsModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CNCreateAccountTxDetailsModel.swift; sourceTree = ""; }; 478C98252942DC2700FAA0F0 /* BuyDashViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BuyDashViewController.swift; sourceTree = ""; }; 478C98282942DDB800FAA0F0 /* BuyDashModel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BuyDashModel.swift; sourceTree = ""; }; @@ -3871,7 +3871,7 @@ C9F42FA729DC09C6001BC549 /* Style */, 11C5F51128E5D0C500F6F135 /* CrowdNode */, 47A50F362912D9A800C70123 /* Payment Controller */, - 4751136A28D9A3BE00223B77 /* Portal */, + 4751136A28D9A3BE00223B77 /* Buy Sell */, 0F6EDFE028C8AE32000427E7 /* Coinbase */, 47AE8BB328C1305E00490F5E /* Explore Dash */, 2AB231CF2196E23200A6E7E6 /* Start */, @@ -5192,16 +5192,16 @@ path = Views; sourceTree = ""; }; - 4751136A28D9A3BE00223B77 /* Portal */ = { + 4751136A28D9A3BE00223B77 /* Buy Sell */ = { isa = PBXGroup; children = ( 4774DCE328F46679008CF87D /* Views */, 478A2C6F28DC551E00AD1420 /* Model */, - 4751136B28D9A3DB00223B77 /* PortalViewController.swift */, + 4751136B28D9A3DB00223B77 /* BuySellPortalViewController.swift */, C9FAABB42AB793CE00878224 /* BuySellPortal.storyboard */, 47838B86290670630003E8AB /* IntegrationViewController.swift */, ); - path = Portal; + path = "Buy Sell"; sourceTree = ""; }; 4751136D28D9B4F400223B77 /* Info Screen */ = { @@ -5341,7 +5341,7 @@ 4774DCE328F46679008CF87D /* Views */ = { isa = PBXGroup; children = ( - 4774DCE428F4668B008CF87D /* PortalServiceItemCell.swift */, + 4774DCE428F4668B008CF87D /* BuySellServiceItemCell.swift */, ); path = Views; sourceTree = ""; @@ -5412,7 +5412,7 @@ isa = PBXGroup; children = ( 4774DCE228F44BAF008CF87D /* VO */, - 478A2C7028DC554200AD1420 /* PortalModel.swift */, + 478A2C7028DC554200AD1420 /* BuySellPortalModel.swift */, 4774DCE028F44BA3008CF87D /* ServiceDataProvider.swift */, 4774DCDC28F43A68008CF87D /* ServiceDataSource.swift */, 7513DA8B2AB9643F005D55F6 /* BaseIntegrationModel.swift */, @@ -8368,7 +8368,7 @@ C9F42F9F29DA82E5001BC549 /* PayableViewController.swift in Sources */, 47AE8C1528C6378E00490F5E /* HairlineView.swift in Sources */, 2A913E9523A3F75F006A2A59 /* DWInitialViewController.m in Sources */, - 4751136C28D9A3DB00223B77 /* PortalViewController.swift in Sources */, + 4751136C28D9A3DB00223B77 /* BuySellPortalViewController.swift in Sources */, 2A7A7BD62348CB6600451078 /* DWSettingsMenuViewController.m in Sources */, 47AE8C1E28C7491C00490F5E /* AboutViewController.swift in Sources */, 2A0C69DA2314727F001B8C90 /* UISpringTimingParameters+DWInit.m in Sources */, @@ -8590,7 +8590,7 @@ 2A0C69C623142AA4001B8C90 /* DWModalPresentationController.m in Sources */, 47AE8C1128C5430300490F5E /* PointOfUseInfoViewController.swift in Sources */, 47C661B428FDCF7800028A8D /* ActionButtonViewController.swift in Sources */, - 4774DCE528F4668B008CF87D /* PortalServiceItemCell.swift in Sources */, + 4774DCE528F4668B008CF87D /* BuySellServiceItemCell.swift in Sources */, 2A7A7BC92347E0D700451078 /* DWBaseFormTableViewCell.m in Sources */, 4751CAC7296FAEBB00F63AC4 /* AccountCell.swift in Sources */, 2A913EA823A79AD2006A2A59 /* DWTransactionListDataProviderStub.m in Sources */, @@ -8613,7 +8613,7 @@ 472D13ED299E6579006903F1 /* CurrencyExchanger_Objc.m in Sources */, 47AE8C0E28C540C100490F5E /* GiftCardInfoViewController.swift in Sources */, 471DD1B8290A92CD00E030C8 /* Tools.swift in Sources */, - 478A2C7128DC554200AD1420 /* PortalModel.swift in Sources */, + 478A2C7128DC554200AD1420 /* BuySellPortalModel.swift in Sources */, 75F51AAF2ABD8D070057B499 /* IntegrationViewController+Coinbase.swift in Sources */, 75C1F0452AE26AC0006929CA /* CoinJoinViewModel.swift in Sources */, 478C98262942DC2700FAA0F0 /* BuyDashViewController.swift in Sources */, @@ -8961,7 +8961,7 @@ C943B51B2A40A54600AF23C5 /* BaseInvitationViewController.swift in Sources */, C9D2C6AE2A320AA000D15901 /* DWInitialViewController.m in Sources */, C943B52D2A40A54600AF23C5 /* DWDashPayContactsUpdater.m in Sources */, - C9D2C6AF2A320AA000D15901 /* PortalViewController.swift in Sources */, + C9D2C6AF2A320AA000D15901 /* BuySellPortalViewController.swift in Sources */, C9D2C6B02A320AA000D15901 /* DWSettingsMenuViewController.m in Sources */, C9D2C6B12A320AA000D15901 /* AboutViewController.swift in Sources */, 751B61C52ADFFD0700D1C2EF /* IntegrationViewController+Uphold.swift in Sources */, @@ -9292,7 +9292,7 @@ C9D2C7A52A320AA000D15901 /* DWModalPresentationController.m in Sources */, C9D2C7A62A320AA000D15901 /* PointOfUseInfoViewController.swift in Sources */, C9D2C7A72A320AA000D15901 /* ActionButtonViewController.swift in Sources */, - C9D2C7A82A320AA000D15901 /* PortalServiceItemCell.swift in Sources */, + C9D2C7A82A320AA000D15901 /* BuySellServiceItemCell.swift in Sources */, C956AF122A5B5949002FAB75 /* PasteboardContentView.swift in Sources */, C9D2C7AA2A320AA000D15901 /* (null) in Sources */, C943B5002A40A54600AF23C5 /* DWDPTxItemView.m in Sources */, @@ -9334,7 +9334,7 @@ C943B5972A40EDDA00AF23C5 /* DWConfirmUsernameViewController.m in Sources */, C9D2C7C52A320AA000D15901 /* GiftCardInfoViewController.swift in Sources */, C9D2C7C62A320AA000D15901 /* Tools.swift in Sources */, - C9D2C7C72A320AA000D15901 /* PortalModel.swift in Sources */, + C9D2C7C72A320AA000D15901 /* BuySellPortalModel.swift in Sources */, C9D2C7C92A320AA000D15901 /* BuyDashViewController.swift in Sources */, C956AF0D2A5B592E002FAB75 /* TappableLabel.swift in Sources */, C9D2C7CA2A320AA000D15901 /* DWModalDismissalAnimation.m in Sources */, @@ -10099,7 +10099,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = dashwallet/dashwallet.entitlements; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = ""; @@ -10229,7 +10229,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = dashwallet/dashwallet.entitlements; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; GCC_PRECOMPILE_PREFIX_HEADER = YES; @@ -10435,7 +10435,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; IBSC_MODULE = WatchApp_Extension; @@ -10457,7 +10457,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; IBSC_MODULE = WatchApp_Extension; @@ -10477,7 +10477,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = C98AA93FF5283EC6405BCE4B /* Pods-WatchApp Extension.debug.xcconfig */; buildSettings = { - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; ENABLE_BITCODE = NO; EXCLUDED_ARCHS = ""; @@ -10504,7 +10504,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = CE02413EF0C60B1D1EDE6457 /* Pods-WatchApp Extension.release.xcconfig */; buildSettings = { - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; ENABLE_BITCODE = NO; EXCLUDED_ARCHS = ""; @@ -11216,7 +11216,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = dashwallet/dashwallet.entitlements; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; GCC_PRECOMPILE_PREFIX_HEADER = YES; @@ -11417,7 +11417,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; IBSC_MODULE = WatchApp_Extension; @@ -11437,7 +11437,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = 556B5EBEBAEA571D74FF69A3 /* Pods-WatchApp Extension.testflight.xcconfig */; buildSettings = { - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; ENABLE_BITCODE = NO; EXCLUDED_ARCHS = ""; @@ -11536,7 +11536,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CLANG_ENABLE_MODULES = YES; CODE_SIGN_ENTITLEMENTS = dashwallet/dashwallet.entitlements; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; GCC_PRECOMPILE_PREFIX_HEADER = YES; @@ -11725,7 +11725,7 @@ buildSettings = { ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; EXCLUDED_ARCHS = ""; IBSC_MODULE = WatchApp_Extension; @@ -11745,7 +11745,7 @@ isa = XCBuildConfiguration; baseConfigurationReference = 29B232FD70BA2EDF87F86A56 /* Pods-WatchApp Extension.testnet.xcconfig */; buildSettings = { - CURRENT_PROJECT_VERSION = 3; + CURRENT_PROJECT_VERSION = 6; DEVELOPMENT_TEAM = 44RJ69WHFF; ENABLE_BITCODE = NO; EXCLUDED_ARCHS = ""; diff --git a/DashWallet/Sources/UI/Portal/BuySellPortal.storyboard b/DashWallet/Sources/UI/Buy Sell/BuySellPortal.storyboard similarity index 97% rename from DashWallet/Sources/UI/Portal/BuySellPortal.storyboard rename to DashWallet/Sources/UI/Buy Sell/BuySellPortal.storyboard index b028e5f02..ec4a9a638 100644 --- a/DashWallet/Sources/UI/Portal/BuySellPortal.storyboard +++ b/DashWallet/Sources/UI/Buy Sell/BuySellPortal.storyboard @@ -1,9 +1,9 @@ - + - + @@ -27,10 +27,10 @@ - + - + @@ -51,7 +51,7 @@ - + @@ -74,13 +74,13 @@ - diff --git a/DashWallet/Sources/UI/Portal/PortalViewController.swift b/DashWallet/Sources/UI/Buy Sell/BuySellPortalViewController.swift similarity index 88% rename from DashWallet/Sources/UI/Portal/PortalViewController.swift rename to DashWallet/Sources/UI/Buy Sell/BuySellPortalViewController.swift index f70329f37..6674557a7 100644 --- a/DashWallet/Sources/UI/Portal/PortalViewController.swift +++ b/DashWallet/Sources/UI/Buy Sell/BuySellPortalViewController.swift @@ -19,19 +19,19 @@ import AuthenticationServices import SwiftUI import UIKit -// MARK: - PortalViewController +// MARK: - BuySellPortalViewController @objc -final class PortalViewController: UIViewController { +final class BuySellPortalViewController: UIViewController { @IBOutlet var subtitleLabel: UILabel! @IBOutlet var collectionView: UICollectionView! @IBOutlet var networkStatusView: UIView! @IBOutlet var closeButton: UIBarButtonItem! - private var dataSource: UICollectionViewDiffableDataSource! - private var currentSnapshot: NSDiffableDataSourceSnapshot! + private var dataSource: UICollectionViewDiffableDataSource! + private var currentSnapshot: NSDiffableDataSourceSnapshot! - private var model = PortalModel() + private var model = BuySellPortalModel() private var hasNetwork: Bool { model.networkStatus == .online } private let topperViewModel = TopperViewModel.shared @@ -111,20 +111,20 @@ final class PortalViewController: UIViewController { } @objc - class func controller() -> PortalViewController { - vc(PortalViewController.self, from: sb("BuySellPortal")) + class func controller() -> BuySellPortalViewController { + vc(BuySellPortalViewController.self, from: sb("BuySellPortal")) } } // MARK: PortalModelDelegate -extension PortalViewController: PortalModelDelegate { +extension BuySellPortalViewController: BuySellPortalModelDelegate { func serviceItemsDidChange() { collectionView.reloadSections([0]) } } -extension PortalViewController { +extension BuySellPortalViewController { private func createLayout() -> UICollectionViewLayout { let itemSize = NSCollectionLayoutSize(widthDimension: .fractionalWidth(1), heightDimension: .estimated(64)) let item = NSCollectionLayoutItem(layoutSize: itemSize) @@ -155,7 +155,7 @@ extension PortalViewController { // MARK: UICollectionViewDelegate, UICollectionViewDataSource -extension PortalViewController: UICollectionViewDelegate, UICollectionViewDataSource { +extension BuySellPortalViewController: UICollectionViewDelegate, UICollectionViewDataSource { func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -> Int { model.items.count } @@ -163,7 +163,7 @@ extension PortalViewController: UICollectionViewDelegate, UICollectionViewDataSo func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell { let item = model.items[indexPath.item] - let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "ItemCell", for: indexPath) as! PortalServiceItemCell + let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "ItemCell", for: indexPath) as! BuySellServiceItemCell cell.update(with: item, isEnabled: hasNetwork) return cell } diff --git a/DashWallet/Sources/UI/Portal/IntegrationViewController.swift b/DashWallet/Sources/UI/Buy Sell/IntegrationViewController.swift similarity index 100% rename from DashWallet/Sources/UI/Portal/IntegrationViewController.swift rename to DashWallet/Sources/UI/Buy Sell/IntegrationViewController.swift diff --git a/DashWallet/Sources/UI/Portal/Model/BaseIntegrationModel.swift b/DashWallet/Sources/UI/Buy Sell/Model/BaseIntegrationModel.swift similarity index 100% rename from DashWallet/Sources/UI/Portal/Model/BaseIntegrationModel.swift rename to DashWallet/Sources/UI/Buy Sell/Model/BaseIntegrationModel.swift diff --git a/DashWallet/Sources/UI/Portal/Model/PortalModel.swift b/DashWallet/Sources/UI/Buy Sell/Model/BuySellPortalModel.swift similarity index 91% rename from DashWallet/Sources/UI/Portal/Model/PortalModel.swift rename to DashWallet/Sources/UI/Buy Sell/Model/BuySellPortalModel.swift index 7172bc6db..87e58be00 100644 --- a/DashWallet/Sources/UI/Portal/Model/PortalModel.swift +++ b/DashWallet/Sources/UI/Buy Sell/Model/BuySellPortalModel.swift @@ -26,9 +26,9 @@ enum Service: CaseIterable { case topper } -// MARK: - PortalModel.Section +// MARK: - BuySellPortalModel.Section -extension PortalModel { +extension BuySellPortalModel { enum Section: Int { case main } @@ -76,19 +76,19 @@ extension Service { } } -// MARK: - PortalModelDelegate +// MARK: - BuySellPortalModelDelegate -protocol PortalModelDelegate: AnyObject { +protocol BuySellPortalModelDelegate: AnyObject { func serviceItemsDidChange(); } -// MARK: - PortalModel +// MARK: - BuySellPortalModel -class PortalModel: NetworkReachabilityHandling { +class BuySellPortalModel: NetworkReachabilityHandling { var networkStatusDidChange: ((NetworkStatus) -> ())? internal var reachabilityObserver: Any! - weak var delegate: PortalModelDelegate? + weak var delegate: BuySellPortalModelDelegate? var items: [ServiceItem] = [] { didSet { diff --git a/DashWallet/Sources/UI/Portal/Model/ServiceDataProvider.swift b/DashWallet/Sources/UI/Buy Sell/Model/ServiceDataProvider.swift similarity index 52% rename from DashWallet/Sources/UI/Portal/Model/ServiceDataProvider.swift rename to DashWallet/Sources/UI/Buy Sell/Model/ServiceDataProvider.swift index f689c719d..24b379cd3 100644 --- a/DashWallet/Sources/UI/Portal/Model/ServiceDataProvider.swift +++ b/DashWallet/Sources/UI/Buy Sell/Model/ServiceDataProvider.swift @@ -24,30 +24,27 @@ protocol ServiceDataProvider { func refresh() } -// MARK: - MookServiceDataProvider - -class MookServiceDataProvider: ServiceDataProvider { - func listenForData(handler: @escaping (([ServiceItem]) -> Void)) { - handler([.init(status: .authorized, service: .uphold), .init(status: .idle, service: .coinbase)]) - } - - func refresh() { } -} - // MARK: - ServiceDataProviderImpl class ServiceDataProviderImpl: ServiceDataProvider { private var handler: (([ServiceItem]) -> Void)? - - private var upholdDataSource: ServiceDataSource = UpholdDataSource() - private var coinbaseDataSource: ServiceDataSource = CoinbaseDataSource() - - private var items: [ServiceItem] = [ - .init(status: .idle, service: .topper) // Topper item doesn't need a data source - ] + private var items: [ServiceItem] init() { - initializeDataSources() + items = [ + .init(service: .uphold, dataProvider: UpholdDataSource()), + .init(service: .topper, dataProvider: nil) + ] + + if CoinbaseDataSource.shouldShow() { + items.insert(.init(service: .coinbase, dataProvider: CoinbaseDataSource()), at: 0) + } + + for item in items { + item.didUpdate = { [weak self] in + self?.updateServices() + } + } } func listenForData(handler: @escaping (([ServiceItem]) -> Void)) { @@ -55,27 +52,12 @@ class ServiceDataProviderImpl: ServiceDataProvider { } func refresh() { - upholdDataSource.refresh() - coinbaseDataSource.refresh() - } - - private func initializeDataSources() { - upholdDataSource.serviceDidUpdate = { [weak self] item in - self?.updateService(with: item) - } - - coinbaseDataSource.serviceDidUpdate = { [weak self] item in - self?.updateService(with: item) + for item in items { + item.refresh() } } - private func updateService(with item: ServiceItem) { - if let idx = items.firstIndex(where: { $0.service == item.service }) { - items[idx] = item - } else { - items.append(item) - } - + private func updateServices() { let sortedItems = items .sorted(by: { $0.usageCount > $1.usageCount }) .sorted(by: { $0.isInUse && !$1.isInUse }) diff --git a/DashWallet/Sources/UI/Portal/Model/ServiceDataSource.swift b/DashWallet/Sources/UI/Buy Sell/Model/ServiceDataSource.swift similarity index 73% rename from DashWallet/Sources/UI/Portal/Model/ServiceDataSource.swift rename to DashWallet/Sources/UI/Buy Sell/Model/ServiceDataSource.swift index 9919c88a5..5bfa382a2 100644 --- a/DashWallet/Sources/UI/Portal/Model/ServiceDataSource.swift +++ b/DashWallet/Sources/UI/Buy Sell/Model/ServiceDataSource.swift @@ -17,19 +17,26 @@ import Combine import Foundation +import StoreKit let kServiceUsageCount = "kServiceUsageCount" +enum Status: Int { + case unknown + case idle + case initializing + case syncing + case authorized + case failed +} + // MARK: - ServiceDataSource class ServiceDataSource { - var serviceDidUpdate: ((ServiceItem) -> Void)! + var serviceDidUpdate: (() -> Void)! - var item: ServiceItem! { - didSet { - serviceDidUpdate?(item) - } - } + var status: Status = .initializing + var dashBalance: UInt64 = 0 func refresh() { assertionFailure("Override it") @@ -42,32 +49,28 @@ class UpholdDataSource: ServiceDataSource { private var dashCard: DWUpholdCardObject! private var isAuthorized: Bool { DWUpholdClient.sharedInstance().isAuthorized } - override init() { - super.init() - - item = .init(status: .initializing, service: .uphold) - } - override func refresh() { if DWUpholdClient.sharedInstance().isAuthorized { - item = ServiceItem(status: .syncing, service: .uphold) - if let balance = DWUpholdClient.sharedInstance().lastKnownBalance as? Decimal { - item = .init(status: .authorized, service: .uphold, dashBalance: balance.plainDashAmount) + self.status = .authorized + self.dashBalance = balance.plainDashAmount } else { DWUpholdClient.sharedInstance().getCards { [weak self] dashCard, _ in self?.dashCard = dashCard if let available = dashCard?.available as? Decimal { - self?.item = .init(status: .authorized, service: .uphold, dashBalance: available.plainDashAmount) + self?.status = .authorized + self?.dashBalance = available.plainDashAmount } else { - self?.item = .init(status: .failed, service: .uphold) + self?.status = .failed } } } } else { - item = ServiceItem(status: .idle, service: .uphold) + status = .idle } + + serviceDidUpdate?() } } @@ -82,12 +85,18 @@ class CoinbaseDataSource: ServiceDataSource { private var userDidChangeListenerHandle: UserDidChangeListenerHandle! private var accountDidChangeHandle: AnyObject? + + static func shouldShow() -> Bool { + if let storefront = SKPaymentQueue.default().storefront { + return storefront.countryCode != "GB" + } else { + return true + } + } override init() { super.init() - item = .init(status: .initializing, service: .coinbase) - userDidChangeListenerHandle = Coinbase.shared.addUserDidChangeListener { [weak self] _ in self?.refresh() } @@ -100,13 +109,16 @@ class CoinbaseDataSource: ServiceDataSource { override func refresh() { if isAuthorized { if let balance = coinbase.lastKnownBalance { - item = ServiceItem(status: .authorized, service: .coinbase, dashBalance: balance) + status = .authorized + dashBalance = balance } else { - item = ServiceItem(status: .syncing, service: .coinbase) + status = .syncing } } else { - item = .init(status: .idle, service: .coinbase) + status = .idle } + + serviceDidUpdate?() } deinit { diff --git a/DashWallet/Sources/UI/Portal/Model/VO/ServiceItem.swift b/DashWallet/Sources/UI/Buy Sell/Model/VO/ServiceItem.swift similarity index 80% rename from DashWallet/Sources/UI/Portal/Model/VO/ServiceItem.swift rename to DashWallet/Sources/UI/Buy Sell/Model/VO/ServiceItem.swift index d7bf283be..b773dffe8 100644 --- a/DashWallet/Sources/UI/Portal/Model/VO/ServiceItem.swift +++ b/DashWallet/Sources/UI/Buy Sell/Model/VO/ServiceItem.swift @@ -43,15 +43,9 @@ class ServiceItem: Hashable { static func == (lhs: ServiceItem, rhs: ServiceItem) -> Bool { lhs.hashValue == rhs.hashValue } - - enum Status: Int { - case unknown - case idle - case initializing - case syncing - case authorized - case failed - } + + private var dataProvider: ServiceDataSource? + var didUpdate: (() -> Void)? var name: String { service.title } var subtitle: String { service.subtitle } @@ -69,16 +63,23 @@ class ServiceItem: Hashable { var isInUse: Bool { status == .syncing || status == .authorized || service == .topper } - init(status: Status, service: Service, dashBalance: UInt64? = nil) { - self.status = status + init(service: Service, dataProvider: ServiceDataSource?) { self.service = service - self.dashBalance = dashBalance - usageCount = service.usageCount - - guard let dashBalance else { return } - - dashBalanceFormatted = dashBalance.formattedDashAmountWithoutCurrencySymbol - fiatBalanceFormatted = Coinbase.shared.currencyExchanger.fiatAmountString(in: App.fiatCurrency, for: dashBalance.dashAmount) + self.status = .idle + self.dashBalance = nil + self.usageCount = service.usageCount + self.dataProvider = dataProvider + self.dataProvider?.serviceDidUpdate = { [weak self] in + self?.status = dataProvider?.status ?? .initializing + self?.dashBalance = dataProvider?.dashBalance ?? 0 + self?.dashBalanceFormatted = self?.dashBalance?.formattedDashAmountWithoutCurrencySymbol + self?.fiatBalanceFormatted = Coinbase.shared.currencyExchanger.fiatAmountString(in: App.fiatCurrency, for: self?.dashBalance?.dashAmount ?? 0) + self?.didUpdate?() + } + } + + func refresh() { + dataProvider?.refresh() } func hash(into hasher: inout Hasher) { @@ -88,7 +89,7 @@ class ServiceItem: Hashable { } } -extension ServiceItem.Status { +extension Status { var iconColor: UIColor { switch self { case .initializing: return .label diff --git a/DashWallet/Sources/UI/Portal/Views/PortalServiceItemCell.swift b/DashWallet/Sources/UI/Buy Sell/Views/BuySellServiceItemCell.swift similarity index 98% rename from DashWallet/Sources/UI/Portal/Views/PortalServiceItemCell.swift rename to DashWallet/Sources/UI/Buy Sell/Views/BuySellServiceItemCell.swift index ea60b7b24..2e1787230 100644 --- a/DashWallet/Sources/UI/Portal/Views/PortalServiceItemCell.swift +++ b/DashWallet/Sources/UI/Buy Sell/Views/BuySellServiceItemCell.swift @@ -17,7 +17,7 @@ import UIKit -class PortalServiceItemCell: UICollectionViewCell { +class BuySellServiceItemCell: UICollectionViewCell { @IBOutlet var iconView: UIImageView! @IBOutlet var titleLabel: UILabel! @IBOutlet var subtitleLabel: UILabel! diff --git a/DashWallet/Sources/UI/CrowdNode/Getting Started/GettingStartedViewController.swift b/DashWallet/Sources/UI/CrowdNode/Getting Started/GettingStartedViewController.swift index ce133921a..10c40d468 100644 --- a/DashWallet/Sources/UI/CrowdNode/Getting Started/GettingStartedViewController.swift +++ b/DashWallet/Sources/UI/CrowdNode/Getting Started/GettingStartedViewController.swift @@ -195,7 +195,7 @@ extension GettingStartedViewController { } private func buyDashAuthenticated() { - let controller = PortalViewController.controller() + let controller = BuySellPortalViewController.controller() let navigationController = BaseNavigationController(rootViewController: controller) self.navigationController?.present(navigationController, animated: true) } diff --git a/DashWallet/Sources/UI/CrowdNode/Portal/CrowdNodePortalViewController.swift b/DashWallet/Sources/UI/CrowdNode/Portal/CrowdNodePortalViewController.swift index 17f4c9f07..2a53241f1 100644 --- a/DashWallet/Sources/UI/CrowdNode/Portal/CrowdNodePortalViewController.swift +++ b/DashWallet/Sources/UI/CrowdNode/Portal/CrowdNodePortalViewController.swift @@ -283,7 +283,7 @@ extension CrowdNodePortalController : UITableViewDelegate, UITableViewDataSource vc.mainAction = { Task { if await self.viewModel.authenticate() { - let controller = PortalViewController.controller() + let controller = BuySellPortalViewController.controller() nvc.pushViewController(controller, animated: true) } } diff --git a/DashWallet/Sources/UI/Home/DWHomeViewController+DWShortcuts.m b/DashWallet/Sources/UI/Home/DWHomeViewController+DWShortcuts.m index c0347fb91..1c77da1e9 100644 --- a/DashWallet/Sources/UI/Home/DWHomeViewController+DWShortcuts.m +++ b/DashWallet/Sources/UI/Home/DWHomeViewController+DWShortcuts.m @@ -147,7 +147,7 @@ - (void)buySellDashAction { } - (void)buySellDashActionAuthenticated { - PortalViewController *controller = [PortalViewController controller]; + BuySellPortalViewController *controller = [BuySellPortalViewController controller]; controller.showCloseButton = true; DWNavigationController *navigationController = diff --git a/DashWallet/Sources/UI/Menu/Main/DWMainMenuViewController.m b/DashWallet/Sources/UI/Menu/Main/DWMainMenuViewController.m index 164219290..1748f87b2 100644 --- a/DashWallet/Sources/UI/Menu/Main/DWMainMenuViewController.m +++ b/DashWallet/Sources/UI/Menu/Main/DWMainMenuViewController.m @@ -135,7 +135,7 @@ - (void)mainMenuContentView:(DWMainMenuContentView *)view didSelectMenuItem:(id< alertIfLockout:YES completion:^(BOOL authenticated, BOOL usedBiometrics, BOOL cancelled) { if (authenticated) { - PortalViewController *controller = [PortalViewController controller]; + BuySellPortalViewController *controller = [BuySellPortalViewController controller]; controller.hidesBottomBarWhenPushed = true; [self.navigationController pushViewController:controller animated:YES]; }