Last active
November 26, 2018 00:17
-
-
Save JoeM-RP/2bf4d7668e646d3f43e1a0179da630fc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// Logging provided by <see cref="Prism.Logging"/> | |
/// </summary> | |
/// <value>The logger</value> | |
public new ILoggerFacade Logger | |
{ | |
get { return this.Logger; } // Prism 7 | |
} | |
/// <summary> | |
/// With Prism, we navigate using a URI format to preserve the stack. We can also | |
/// reset or rearrage the stack by manipulating the URI, or perform "deep linking" | |
/// when the app is launched with parameters (i.e - email link, push notification, etc) | |
/// </summary> | |
protected override void OnInitialized() | |
{ | |
InitializeComponent(); | |
NavigationService.NavigateAsync($"myapp:///Root/Navigation/{nameof(Views.HomePage)}"); | |
} | |
/// <summary> | |
/// Registers the types. Notice that we can set the name explicity by providing the | |
/// name parameter, or just use the nameof property for the page | |
/// </summary> | |
protected override void RegisterTypes(IContainerRegistry containerRegistry) | |
{ | |
// Register Navigation page | |
containerRegistry.RegisterForNavigation<Views.AppShellNavigationPage>("Navigation"); | |
// Register Views | |
containerRegistry.RegisterForNavigation<Views.AppShell>("Root"); | |
containerRegistry.RegisterForNavigation<Views.HomePage>(); | |
containerRegistry.RegisterForNavigation<Views.SamplePage>(); | |
containerRegistry.RegisterForNavigation<Views.SettingsPage>(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment