mirror of
https://github.com/inotia00/revanced-patches.git
synced 2025-06-12 13:17:46 +02:00
feat(YouTube Music): rename patch Start page
→ Change start page
This commit is contained in:
@ -18,8 +18,8 @@ import app.revanced.util.exception
|
||||
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
|
||||
@Patch(
|
||||
name = "Start page",
|
||||
description = "Set the default start page.",
|
||||
name = "Change start page",
|
||||
description = "Changes the start page of the app.",
|
||||
dependencies = [
|
||||
IntentHookPatch::class,
|
||||
SettingsPatch::class
|
||||
@ -27,7 +27,7 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")]
|
||||
)
|
||||
@Suppress("unused")
|
||||
object StartPagePatch : BytecodePatch(
|
||||
object ChangeStartPagePatch : BytecodePatch(
|
||||
setOf(ColdStartUpFingerprint)
|
||||
) {
|
||||
override fun execute(context: BytecodeContext) {
|
||||
@ -39,7 +39,7 @@ object StartPagePatch : BytecodePatch(
|
||||
|
||||
addInstructions(
|
||||
targetIndex + 1, """
|
||||
invoke-static {v$targetRegister}, $GENERAL->setStartPage(Ljava/lang/String;)Ljava/lang/String;
|
||||
invoke-static {v$targetRegister}, $GENERAL->changeStartPage(Ljava/lang/String;)Ljava/lang/String;
|
||||
move-result-object v$targetRegister
|
||||
return-object v$targetRegister
|
||||
"""
|
||||
@ -55,7 +55,7 @@ object StartPagePatch : BytecodePatch(
|
||||
|
||||
SettingsPatch.addMusicPreferenceWithIntent(
|
||||
CategoryType.GENERAL,
|
||||
"revanced_start_page"
|
||||
"revanced_change_start_page"
|
||||
)
|
||||
|
||||
}
|
Reference in New Issue
Block a user