コード例 #1
0
        private void OnFinishDownloading(bool res, int ep, string shortCode)
        {
            if (ShortCode != shortCode)
            {
                return;
            }
            var episodeToUse = _episodes[ep];

            episodeToUse.IsDownloaded = res;
            Config.Instance.SaveConfig();
            FileDownloader.OnDownloadFinishedEvent -= OnFinishDownloading;
            PodcastFunctions.UpdateLatestPodcastList().ConfigureAwait(false);
        }
コード例 #2
0
        public async Task InitializePodcasts()
        {
            isLoading = true;
            foreach (var pod in config.ConfigObject.PodcastMap.Podcasts)
            {
                await pod.Value.CheckForNew();

                await pod.Value.FillNewEpisodes();

                await pod.Value.CheckForDownloadedEpisodes();
            }
            await PodcastFunctions.UpdateLatestPodcastList().ConfigureAwait(false);

            await PodcastFunctions.UpdateLatestPlayedList().ConfigureAwait(false);

            errorData.Error = "";
            VlcApi.DoNothing();
            isLoading = false;
        }