Skip to content

Commit

Permalink
fix: home tab filter adds rules for bangumi_v2 and cinema_v2 (yujinch…
Browse files Browse the repository at this point in the history
  • Loading branch information
CodePwn2021 authored Nov 13, 2024
1 parent d7f0d82 commit 8c7fd1a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions app/src/main/java/me/iacn/biliroaming/hook/JsonHook.kt
Original file line number Diff line number Diff line change
Expand Up @@ -471,9 +471,14 @@ class JsonHook(classLoader: ClassLoader) : BaseHook(classLoader) {
var hasKoreaTW = false
tab.forEach {
when (it.getObjectFieldAs<String>("uri")) {
"bilibili://pgc/bangumi_v2",
"bilibili://pgc/home" -> hasBangumiCN = true

"bilibili://following/home_activity_tab/6544" -> hasBangumiTW = true

"bilibili://pgc/cinema_v2",
"bilibili://pgc/home?home_flow_type=2" -> hasMovieCN = true

"bilibili://following/home_activity_tab/168644" -> hasMovieTW = true
"bilibili://following/home_activity_tab/163541" -> hasKoreaHK = true
"bilibili://following/home_activity_tab/95636" -> hasKoreaTW = true
Expand Down Expand Up @@ -556,10 +561,12 @@ class JsonHook(classLoader: ClassLoader) : BaseHook(classLoader) {
"bilibili://pegasus/hottopic"
-> purifytabset.contains("hottopic")

"bilibili://pgc/bangumi_v2",
"bilibili://pgc/home",
"bilibili://following/home_activity_tab/6544"
-> purifytabset.contains("bangumi")

"bilibili://pgc/cinema_v2",
"bilibili://pgc/home?home_flow_type=2",
"bilibili://following/home_activity_tab/168644"
-> purifytabset.contains("movie")
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values-zh-rTW/arrays.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<item>直播</item>
<item>推薦</item>
<item>熱門</item>
<item>番劇</item>
<item>番劇(動畫)</item>
<item>影視</item>
<item>韓綜</item>
<item>其它</item>
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values/arrays.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
<item>直播</item>
<item>推荐</item>
<item>热门</item>
<item>番剧</item>
<item>番剧(动画)</item>
<item>影视</item>
<item>韩综</item>
<item>其它</item>
Expand Down

0 comments on commit 8c7fd1a

Please sign in to comment.