Skip to content

Commit

Permalink
Switch Aniwatch to Kaido. (Closes #22)
Browse files Browse the repository at this point in the history
  • Loading branch information
jerry08 committed Jul 29, 2023
1 parent fdca069 commit 28c7202
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion AniStream/Adapters/ViewPagerAdapter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public ViewPagerAdapter(FragmentManager fm) : base(fm)
Fragments.Add(AnimeFragment.NewInstance(SearchFilter.NewSeason));
Fragments.Add(AnimeFragment.NewInstance(SearchFilter.LastUpdated));
break;
case AnimeSites.Aniwatch:
case AnimeSites.Kaido:
Fragments.Add(AnimeFragment.NewInstance(SearchFilter.Popular));
Fragments.Add(AnimeFragment.NewInstance(SearchFilter.NewSeason));
Fragments.Add(AnimeFragment.NewInstance(SearchFilter.TopAiring));
Expand Down
2 changes: 1 addition & 1 deletion AniStream/Fragments/AnimeFragment.cs
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ or AnimeSites.AnimePahe
SearchFilter.LastUpdated => await provider.GetLastUpdatedAsync(Page),
_ => throw new NotImplementedException(),
},
Aniwatch provider => _searchFilter switch
Kaido provider => _searchFilter switch
{
SearchFilter.Popular => await provider.GetPopularAsync(Page),
SearchFilter.NewSeason => await provider.GetRecentlyAddedAsync(Page),
Expand Down
12 changes: 6 additions & 6 deletions AniStream/MainActivity.cs
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ private void SetupViewPager()
case AnimeSites.GogoAnime:
bottomNavigationView.InflateMenu(Resource.Menu.bottommenu2);
break;
case AnimeSites.Aniwatch:
case AnimeSites.Kaido:
bottomNavigationView.InflateMenu(Resource.Menu.bottommenu4);
break;
case AnimeSites.AnimePahe:
Expand Down Expand Up @@ -398,7 +398,7 @@ private async void SetupSources(IMenu menu)
WeebUtils.AnimeSite = (AnimeSites)Convert.ToInt32(animeSiteStr);

var gogoanime = menu.FindItem(Resource.Id.source_gogoanime);
var aniwatch = menu.FindItem(Resource.Id.source_aniwatch);
var kaido = menu.FindItem(Resource.Id.source_kaido);
var animepahe = menu.FindItem(Resource.Id.source_animepahe);
var nineanime = menu.FindItem(Resource.Id.source_nineanime);
var otakudesu = menu.FindItem(Resource.Id.source_otakudesu);
Expand All @@ -408,8 +408,8 @@ private async void SetupSources(IMenu menu)
case AnimeSites.GogoAnime:
gogoanime?.SetChecked(true);
break;
case AnimeSites.Aniwatch:
aniwatch?.SetChecked(true);
case AnimeSites.Kaido:
kaido?.SetChecked(true);
break;
case AnimeSites.AnimePahe:
animepahe?.SetChecked(true);
Expand Down Expand Up @@ -467,8 +467,8 @@ private async void SaveSelectedSource(int id)

if (id == Resource.Id.source_gogoanime)
WeebUtils.AnimeSite = AnimeSites.GogoAnime;
else if (id == Resource.Id.source_aniwatch)
WeebUtils.AnimeSite = AnimeSites.Aniwatch;
else if (id == Resource.Id.source_kaido)
WeebUtils.AnimeSite = AnimeSites.Kaido;
else if (id == Resource.Id.source_animepahe)
WeebUtils.AnimeSite = AnimeSites.AnimePahe;
else if (id == Resource.Id.source_nineanime)
Expand Down
6 changes: 3 additions & 3 deletions AniStream/Resources/menu/drawer.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
android:titleCondensed="Gogoanime"
android:title="Gogoanime"
app:actionViewClass="android.widget.RadioButton" />
<item android:id="@+id/source_aniwatch"
android:titleCondensed="Aniwatch"
android:title="Aniwatch"
<item android:id="@+id/source_kaido"
android:titleCondensed="Kaido"
android:title="Kaido"
app:actionViewClass="android.widget.RadioButton" />
<item android:id="@+id/source_animepahe"
android:titleCondensed="Anime Pahe"
Expand Down
2 changes: 1 addition & 1 deletion AniStream/Utils/WeebUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public static IAnimeProvider AnimeClient

return AnimeSite switch
{
AnimeSites.Aniwatch => new Aniwatch(() => httpClient),
AnimeSites.Kaido => new Kaido(() => httpClient),
AnimeSites.AnimePahe => new AnimePahe(() => httpClient),
AnimeSites.NineAnime => new NineAnime(() => httpClient),
AnimeSites.OtakuDesu => new OtakuDesu(() => httpClient),
Expand Down

0 comments on commit 28c7202

Please sign in to comment.