public AnimeTimelineVM(AnimeType type)
 {
     animeApi       = new Api.Home.AnimeAPI();
     AnimeTypeItems = new List <AnimeTypeItem>()
     {
         new AnimeTypeItem()
         {
             Name      = "番剧",
             AnimeType = AnimeType.bangumi
         },
         new AnimeTypeItem()
         {
             Name      = "国创",
             AnimeType = AnimeType.guochuang
         }
     };
     SelectAnimeType = AnimeTypeItems.FirstOrDefault(x => x.AnimeType == type);
     animeType       = type;
 }
Beispiel #2
0
 public AnimeVM(AnimeType type)
 {
     bangumiApi = new Api.Home.AnimeAPI();
     followAPI  = new Api.User.FollowAPI();
     animeType  = type;
     Entrances  = new List <PageEntranceModel>()
     {
         new PageEntranceModel()
         {
             Logo           = "ms-appx:///Assets/Icon/榜单.png",
             Name           = "热门榜单",
             NavigationInfo = new NavigationInfo()
             {
                 icon       = Symbol.FourBars,
                 page       = typeof(SeasonRankPage),
                 title      = "热门榜单",
                 parameters = (int)type
             }
         },
         new PageEntranceModel()
         {
             Logo           = "ms-appx:///Assets/Icon/索引.png",
             Name           = "索引",
             NavigationInfo = new NavigationInfo()
             {
                 icon       = Symbol.Filter,
                 page       = typeof(AnimeIndexPage),
                 title      = "索引",
                 parameters = new SeasonIndexParameter()
                 {
                     type = IndexSeasonType.Anime,
                     area = animeType == AnimeType.bangumi?"-1":"1,6,7"
                 }
             }
         },
         new PageEntranceModel()
         {
             Logo           = "ms-appx:///Assets/Icon/时间表.png",
             Name           = "时间表",
             NavigationInfo = new NavigationInfo()
             {
                 icon       = Symbol.Filter,
                 page       = typeof(TimelinePage),
                 title      = "时间表",
                 parameters = animeType
             }
         },
         new PageEntranceModel()
         {
             Logo           = "ms-appx:///Assets/Icon/我的.png",
             Name           = "我的追番",
             NavigationInfo = new NavigationInfo()
             {
                 icon       = Symbol.OutlineStar,
                 page       = typeof(FavoritePage),
                 title      = "我的追番",
                 parameters = OpenFavoriteType.Bangumi
             }
         },
     };
 }