コード例 #1
0
ファイル: App.xaml.cs プロジェクト: utd-github/Nasiye
        public App()
        {
            InitializeComponent();


            Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MTI1OTgzQDMxMzcyZTMyMmUzMFhldFRrMmk3SWdoY3g2bEFBd29yNWJRNlRib3RWK3lITWszbW1tRlozdW89");

            InitializeComponent();

            NetworkAccess current = Connectivity.NetworkAccess;


            if (current == NetworkAccess.Internet)
            {
                var auth = DependencyService.Get <IFirebaseAuthService>().GetCurrentUser();

                if (auth != null)
                {
                    MainPage = new MainContainerPage();
                }
                else
                {
                    MainPage = new NavigationPage(new GettingStartedPage());
                }
            }
            else
            {
                MainPage = new NavigationPage(new CheckPage());
            }
        }
コード例 #2
0
        public static Page GetMainPage()
        {
            TinyIoC.TinyIoCContainer.Current.Register <IDataSourceFactory, DataSourceFactory> ().AsSingleton();

            var tabbedPage = new MainContainerPage();

            TinyIoC.TinyIoCContainer.Current.Register <ITabbedNavigation> (tabbedPage);

            return(tabbedPage);
        }