void Req_Completed(Film.RootObject deserialized) { Data = deserialized; if (getCompleted != null) { getCompleted(Data); } }
protected override void OnNavigatedTo(NavigationEventArgs e) { base.OnNavigatedTo(e); listSalonlar.SelectedIndex = -1; listOyuncular.SelectedIndex = -1; MovieID = NavigationContext.QueryString["ID"]; GeoCoordinateWatcher geoWatch = new GeoCoordinateWatcher(GeoPositionAccuracy.Default); geoWatch.MovementThreshold = 500; geoWatch.PositionChanged +=geoWatch_PositionChanged; geoWatch.Start(); Film birFilm = new Film(); birFilm.getCompleted +=birFilm_getCompleted; birFilm.get(MovieID); }
void birFilm_getCompleted(Film.RootObject data) { loader.IsIndeterminate = false; PanoramaRoot.Title = data.movie.name; film_hakkinda.DataContext = data.movie; listOyuncular.ItemsSource = data.artists; listYorumlar.ItemsSource = data.comments; var Url = data.movie.trailerUrl; if (Url != "False") { ((ApplicationBarIconButton)this.ApplicationBar.Buttons[0]).IsEnabled = true; } else { ((ApplicationBarIconButton)this.ApplicationBar.Buttons[0]).IsEnabled = false; } MoviePhotos moviePhotos = new MoviePhotos(); moviePhotos.getCompleted += moviePhotos_getCompleted; moviePhotos.get(data.movie.id); }