private void RegisterViewModels() { HomePageViewModel.Register(_homePage); SearchPageViewModel.Register(_searchPage); PrivacyModeViewModel.Register(_privacyMode); AddWalletPageViewModel.Register(_addWalletPage); SettingsPageViewModel.Register(_settingsPage); GeneralSettingsTabViewModel.RegisterLazy( () => { _settingsPage.SelectedTab = 0; return(_settingsPage); }); PrivacySettingsTabViewModel.RegisterLazy( () => { _settingsPage.SelectedTab = 1; return(_settingsPage); }); NetworkSettingsTabViewModel.RegisterLazy( () => { _settingsPage.SelectedTab = 2; return(_settingsPage); }); BitcoinTabSettingsViewModel.RegisterLazy( () => { _settingsPage.SelectedTab = 3; return(_settingsPage); }); AboutViewModel.RegisterLazy(() => new AboutViewModel()); BroadcastTransactionViewModel.RegisterAsyncLazy( async() => { var result = await DialogScreen.NavigateDialog(new LoadTransactionViewModel(_global.Network)); if (result is { }) { while (_global.TransactionBroadcaster is null) { await Task.Delay(100); } DialogScreen.Back(); return(new BroadcastTransactionViewModel( _global.BitcoinStore, _global.Network, _global.TransactionBroadcaster, result)); } DialogScreen.Back(); return(null); });