コード例 #1
0
ファイル: App.cs プロジェクト: phaufe/MvvmNano
        private void SetUpMainPage()
        {
            var viewModel = MvvmNanoIoC.Resolve<LoginViewModel>();
            viewModel.Initialize();

            var page = new LoginPage();
            page.SetViewModel(viewModel);

            MainPage = new MvvmNanoNavigationPage(page);
        }
コード例 #2
0
 private void SetMainPage(Page page)
 {
     if (page is MasterDetailPage)
     {
         MainPage = page;
     }
     else
     {
         MainPage = new MvvmNanoNavigationPage(page);
     }
 }
コード例 #3
0
 /// <summary>
 /// Sets up the main page for the given View Model type and parameter.
 /// </summary>
 protected void SetUpMainPage <TViewModel, TNavigationParameter>(TNavigationParameter navigationParameter) where TViewModel : IViewModel <TNavigationParameter>
 {
     MainPage = new MvvmNanoNavigationPage(GetPageFor <TViewModel, TNavigationParameter>(navigationParameter));
 }
コード例 #4
0
 /// <summary>
 /// Sets up the main page for the given View Model type.
 /// </summary>
 protected void SetUpMainPage <TViewModel>() where TViewModel : MvvmNanoViewModel
 {
     MainPage = new MvvmNanoNavigationPage(GetPageFor <TViewModel>());
 }