コード例 #1
0
        async Task LoadMovieList(ObservableCollection <Movie> List, string Path, Dictionary <string, string> Query)
        {
            var results = await Task.Run(() => TMDBService.GetMovieList(Path, Query, 1, 1));

            foreach (var v in results)
            {
                List.Add(v);
            }
        }
コード例 #2
0
        async Task LoadRecommendations()
        {
            var recommendations = await Task.Run(() => TMDBService.GetMovieList($"/movie/{Id}/recommendations", new Dictionary <string, string>()));

            foreach (var v in recommendations.ImagesFirst())
            {
                Recommendations.Add(v);
            }
        }
コード例 #3
0
        async Task LoadSimilar()
        {
            var similar = await Task.Run(() => TMDBService.GetMovieList($"/movie/{Id}/similar", new Dictionary <string, string>()));

            foreach (var v in similar.ImagesFirst())
            {
                Similar.Add(v);
            }
        }
コード例 #4
0
        public async Task LoadData()
        {
            LoadedPages++;
            var results = await Task.Run(() => TMDBService.GetMovieList(Path, Query, LoadedPages, 1));

            if (results.Count != 0)
            {
                LoadedMore();
            }
            foreach (var v in results)
            {
                Movies.Add(v);
            }
        }