fix(YouTube Music - Hide cast button): Resolve button not hiding
This commit is contained in:
parent
9afe9afc67
commit
7817885cff
1 changed files with 6 additions and 0 deletions
|
|
@ -9,6 +9,9 @@ import app.revanced.patches.all.misc.resources.addResourcesPatch
|
||||||
import app.revanced.patches.music.misc.extension.sharedExtensionPatch
|
import app.revanced.patches.music.misc.extension.sharedExtensionPatch
|
||||||
import app.revanced.patches.music.misc.settings.PreferenceScreen
|
import app.revanced.patches.music.misc.settings.PreferenceScreen
|
||||||
import app.revanced.patches.music.misc.settings.settingsPatch
|
import app.revanced.patches.music.misc.settings.settingsPatch
|
||||||
|
import app.revanced.patches.shared.misc.mapping.get
|
||||||
|
import app.revanced.patches.shared.misc.mapping.resourceMappingPatch
|
||||||
|
import app.revanced.patches.shared.misc.mapping.resourceMappings
|
||||||
import app.revanced.patches.shared.misc.settings.preference.SwitchPreference
|
import app.revanced.patches.shared.misc.settings.preference.SwitchPreference
|
||||||
import app.revanced.util.indexOfFirstInstructionOrThrow
|
import app.revanced.util.indexOfFirstInstructionOrThrow
|
||||||
import app.revanced.util.indexOfFirstLiteralInstructionOrThrow
|
import app.revanced.util.indexOfFirstLiteralInstructionOrThrow
|
||||||
|
|
@ -29,6 +32,7 @@ val hideCastButton = bytecodePatch(
|
||||||
sharedExtensionPatch,
|
sharedExtensionPatch,
|
||||||
settingsPatch,
|
settingsPatch,
|
||||||
addResourcesPatch,
|
addResourcesPatch,
|
||||||
|
resourceMappingPatch
|
||||||
)
|
)
|
||||||
|
|
||||||
compatibleWith(
|
compatibleWith(
|
||||||
|
|
@ -39,6 +43,8 @@ val hideCastButton = bytecodePatch(
|
||||||
)
|
)
|
||||||
|
|
||||||
execute {
|
execute {
|
||||||
|
playerOverlayChip = resourceMappings["id", "player_overlay_chip"]
|
||||||
|
|
||||||
addResources("music", "layout.castbutton.hideCastButton")
|
addResources("music", "layout.castbutton.hideCastButton")
|
||||||
|
|
||||||
PreferenceScreen.GENERAL.addPreferences(
|
PreferenceScreen.GENERAL.addPreferences(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue