public SplashPage(SplashPageViewModel splashPageViewModel) { InitializeComponent(); _splashPageViewModel = splashPageViewModel; _splashPageViewModel.ConnectedToPage = this; BindingContext = _splashPageViewModel; }
//====================================================================== /*----------------------------------------- * * Constructor will load the appropriate * splash image * * ---------------------------------------*/ public SplashPage() { InitializeComponent(); spvm = new SplashPageViewModel(); if (spvm.orientation == Screen.Orientation.landscape) { ImageTag.Source = "splash_landscape.png"; } else if (spvm.orientation == Screen.Orientation.portrait) { ImageTag.Source = "splash_portrait.png"; } }
public SplashPage() { InitializeComponent(); BindingContext = new SplashPageViewModel(Navigation); //Device.StartTimer(TimeSpan.FromMilliseconds(200), () => //{ // ProgressInitilize.Progress += 0.01; // if (ProgressInitilize.Progress > .5) // { // ProgressInitilize.Progress = 0; // return false; // } // return true; //}); }
public void OnNavigatedToTest() { SplashPageViewModel unitUnderTest = CreateViewModel(); unitUnderTest.OnNavigatedTo(SplashPage.BuildNavigationParams(Destination.ContactedNotifyPage, new NavigationParameters { { "test-key", "test-value" } })); _mockMigrationService.Verify(x => x.MigrateAsync(), Times.Once()); _mockSplashNavigationService.VerifySet(x => x.Destination = Destination.ContactedNotifyPage, Times.Once()); _mockSplashNavigationService.VerifySet(x => x.DestinationPageParameters = It.Is <INavigationParameters>(x => x.ContainsKey("test-key") && x.GetValue <string>("test-key") == "test-value"), Times.Once() ); _mockSplashNavigationService.Verify(x => x.Prepare(), Times.Once()); _mockSplashNavigationService.Verify(x => x.NavigateNextAsync(false), Times.Once()); }