Beispiel #1
0
        async protected override Task <DataListPageResult <TVShowVm> > FetchPageAsync(int pageNumber)
        {
            var tvshow = await _appContext.XBMC.VideoLibrary.GetTVShowDetails(_id, TVShow.AllFields());

            var vm = new TVShowVm(tvshow.tvshowdetails, _appContext, false);

            var list = new List <TVShowVm>()
            {
                vm
            };

            return(new DataListPageResult <TVShowVm>(1, PageSize, pageNumber, list));
        }
Beispiel #2
0
        private async Task GetRecent()
        {
            try
            {
                var movies = await _server.XBMC.VideoLibrary.GetTVShows(TVShow.AllFields(), new Limits()
                {
                    end = 12, start = 0
                }, new Sort()
                {
                    method = Sort_method.dateadded, ignorearticle = true, order = Sort_order.descending
                });

                RefreshTops(movies.tvshows.Select(MovieFactory).ToList());
            }
            catch (Exception)
            {
                throw;
            }
        }
Beispiel #3
0
        public async Task <TVShowVm> GetTVShow(int tvshowid)
        {
            if (_lastTvShow != null && _lastTvShow.ID == tvshowid)
            {
                return(_lastTvShow);
            }
            var tvshow = await _appContext.XBMC.VideoLibrary.GetTVShowDetails(tvshowid, TVShow.AllFields());

            _lastTvShow = new TVShowVm(tvshow.tvshowdetails, _appContext, false);
            return(_lastTvShow);
        }
Beispiel #4
0
        private async void ButtonBase_OnClick(object sender, RoutedEventArgs e)
        {
            System.Collections.Generic.List <string> s;
            IPlatformServices platformServices = new PlatformServices();
            var xbmc = new Client(platformServices, "localhost", 85);
            var m    = await xbmc.VideoLibrary.GetMovies(new XBMCRPC.List.Filter.Rule.Movies()
            {
                field = Movies.playcount, Operator = Operators.Is, value = "0"
            }, Movie.AllFields(), new Limits()
            {
                start = 1, end = 10
            });

            xbmc.Playlist.OnClear += Playlist_OnClear;

            //await xbmc.StartNotificationListener();

            var p = await xbmc.Application.GetProperties(GetProperties_properties.AllFields());

            var wellKnownPlayerIdVideo         = 1; //or use xbmc.Player.GetActivePlayers()
            var playerPropertiesPercentageOnly = await xbmc.Player.GetProperties(1, new XBMCRPC.Player.GetProperties_properties()
            {
                XBMCRPC.Player.Property.Name.percentage
            });

            var playerPropertiesAll = await xbmc.Player.GetProperties(1, XBMCRPC.Player.GetProperties_properties.AllFields());

            var ret0 = await xbmc.JSONRPC.Introspect();

            var ret1 = await xbmc.Application.GetProperties(GetProperties_properties.AllFields());

            var ret2 = await xbmc.VideoLibrary.GetTVShows(TVShow.AllFields());

            var ret3 = await xbmc.VideoLibrary.SetMovieDetails(3, playcount : 10);

            var ret4 = await xbmc.VideoLibrary.GetMovies(Movie.AllFields(), new Limits()
            {
                start = 1, end = 10
            });

            var ret4a = await xbmc.Files.PrepareDownload(ret4.movies[0].thumbnail);

            var unlistedFiles = await GetUnlistedFiles(xbmc);


            var ret5 = await xbmc.Files.GetSources();

            var ret5a = await xbmc.Files.GetDirectory(ret5.sources[5].file);

            var ret5b = await xbmc.Files.GetDirectory(ret5a.files[0].file);

            var ret5c = await xbmc.Files.GetDirectory(ret5b.files[0].file, Media.files, Files.AllFields());

            var ret5d = await xbmc.Files.GetDirectory("C:\\Archiv\\Serien1\\How I met your Mother\\Staffel 3", Media.video);

            var ret5e = await xbmc.Files.GetDirectory("C:\\Archiv\\HD2", Media.video, Files.AllFields());

            var ret6 = await xbmc.Files.GetDirectory(@"C:\Users\steve_000\Music\Amazon MP3\die ärzte\auch", Media.music, Files.AllFields());

            var ret7 = await xbmc.Playlist.GetItems(0, properties : All.AllFields());

            var ret7a = await xbmc.Playlist.GetItems(1, properties : All.AllFields());

            var ret8 = await xbmc.Playlist.GetPlaylists();

            var ret9 = await xbmc.Player.GetActivePlayers();

            Sample_GetImageToCurrentPlayingItem(xbmc);
        }