protected override async void OnNavigatedTo(NavigationEventArgs e) { await TitleBarHelper.SetVisibilityAsync(Windows.UI.Xaml.Visibility.Collapsed); TitleBarHelper.SetButtonBackgroundColor(Colors.Transparent); TitleBarHelper.SetButtonForegroundColor(Colors.White); }
protected override async void OnNavigatedTo(NavigationEventArgs e) { base.OnNavigatedTo(e); await TitleBarHelper.SetVisibilityAsync(Windows.UI.Xaml.Visibility.Collapsed); TitleBarHelper.SetButtonBackgroundColor(Colors.Transparent); TitleBarHelper.SetButtonForegroundColor(Colors.White); var snm = SystemNavigationManager.GetForCurrentView(); snm.BackRequested -= App.GlobalBackRequested; snm.BackRequested += LoginPage_BackRequested; Messenger.Default.Register <NotificationMessage>(this, message => { ShowAlertGridStoryboard.Begin(); AlertDescriptionTextBlock.Text = message.Notification; }); ViewModel.PropertyChanged += (s, args) => { if (args.PropertyName.Equals(nameof(ViewModel.CurrentStep))) { SystemNavigationManager.GetForCurrentView().AppViewBackButtonVisibility = ViewModel.PreviousCommand.CanExecute(null) ? AppViewBackButtonVisibility.Visible : AppViewBackButtonVisibility.Collapsed; } }; }
protected override async void OnNavigatedTo(NavigationEventArgs e) { await TitleBarHelper.SetVisibilityAsync(Visibility.Collapsed); TitleBarHelper.SetButtonBackgroundColor(Colors.Transparent); TitleBarHelper.SetButtonForegroundColor(ForegroundBrush.Color); Messenger.Default.Register <LoadContentMessage>(this, message => { HtmlViewer.NavigateToString(ViewModel.FormattedHtml); }); Messenger.Default.Register <TagsEditedMessage>(this, async message => { if (message.Item.Id == ViewModel.Item.Model.Id) { await HtmlViewer.InvokeScriptAsync("updateTagsElement", new List <string>() { ViewModel.BuildTagsHtml(message.Item) }); } }); }