コード例 #1
0
ファイル: ExplosmViewModel.cs プロジェクト: GaaH/Comics
        private async void ResumeComicAsync()
        {
            if (Comic == null)
            {
                var comicUri = ComicSettings.ExplosmSettings.LastViewedUri;

                if (comicUri == null)
                {
                    Comic = await ComicProvider.LoadLatestComicAsync();
                }
                else
                {
                    Comic = await ComicProvider.LoadComicAsync(comicUri);
                }
            }
        }
コード例 #2
0
ファイル: XkcdViewModel.cs プロジェクト: GaaH/Comics
        private async void ResumeComic()
        {
            if (Comic == null)
            {
                var       comicUri = ComicSettings.XkcdSettings.LastViewedUri;
                XkcdComic xkcd     = null;

                if (comicUri == null)
                {
                    xkcd = (XkcdComic)await ComicProvider.LoadLatestComicAsync();
                }
                else
                {
                    xkcd = (XkcdComic)await ComicProvider.LoadComicAsync(comicUri);
                }

                Comic       = xkcd;
                Description = xkcd.Description;
            }
        }
コード例 #3
0
 private async void LoadLatestComicAsync()
 {
     Comic = await ComicProvider.LoadLatestComicAsync();
 }