public void OnPlceNumberTap(object sender, EventArgs e) { var ojbPlceNumber = sender as Grid; var objData = ojbPlceNumber.BindingContext as TourLocation; SelectedTour = objData; routeCoversListBindData(System.Int32.Parse(objData.placeNumberTitle) - 1); if (player != null) { player.Stop(); } UpdateScreenData(objData); if (SelectedTour.location_audio == "") { timer.StopTimer(); AudioPlayerGrid.IsVisible = false; stckDownload.IsVisible = false; } else { AudioPlayerGrid.IsVisible = true; stckDownload.IsVisible = true; if (timer != null) { timer.StopTimer(); timer = null; timer = DependencyService.Get <IAdvancedTimer>(); timer.InitTimer(3000, timerElapsed, false); timer.StartTimer(); } } SelectTourIndex = System.Convert.ToInt32(objData.placeNumberTitle); }
protected async override void OnAppearing() { _isCurrentPage = true; await Task.Delay(100); _timer.StartTimer(); base.OnAppearing(); }
public void timerElapsed(object o, EventArgs e) { Xamarin.Forms.Device.BeginInvokeOnMainThread(() => { LoadAudioFile(SelectedTour); timer.StopTimer(); var x = timer.IsTimerEnabled; // timer = null; //timer = DependencyService.Get<IAdvancedTimer>(); timer.InitTimer(1000, UpdatePosition, true); timer.StartTimer(); }); }
protected override void OnAppearing() { imgHeader.Source = _tourPlaceURl; routeCoversListBindData(0); UpdateScreenData(_routeCovers[0]); SelectedTour = _routeCovers[0]; timer = DependencyService.Get <IAdvancedTimer>(); timer.InitTimer(3000, timerElapsed, false); timer.StartTimer(); if (Device.OS == TargetPlatform.Android) { MapBindpinsInMap(_responseMap); } }
void InitiateTimer() { _timer.InitTimer(5000, InitiateMotionCarousel(), true); _timer.StartTimer(); }