diff --git a/src/main/kotlin/app/revanced/patches/music/general/startpage/StartPagePatch.kt b/src/main/kotlin/app/revanced/patches/music/general/startpage/ChangeStartPagePatch.kt similarity index 90% rename from src/main/kotlin/app/revanced/patches/music/general/startpage/StartPagePatch.kt rename to src/main/kotlin/app/revanced/patches/music/general/startpage/ChangeStartPagePatch.kt index 71f31afeb..4080639b4 100644 --- a/src/main/kotlin/app/revanced/patches/music/general/startpage/StartPagePatch.kt +++ b/src/main/kotlin/app/revanced/patches/music/general/startpage/ChangeStartPagePatch.kt @@ -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" ) } diff --git a/src/main/resources/music/settings/host/values/strings.xml b/src/main/resources/music/settings/host/values/strings.xml index 5fd6f05de..0a1d17769 100644 --- a/src/main/resources/music/settings/host/values/strings.xml +++ b/src/main/resources/music/settings/host/values/strings.xml @@ -15,6 +15,13 @@ Navigation Player Video + Chart + Explore + Home + Library + Subscription + Changes the start page of the app. + Change start page Automatically close interstitial ads. Close interstitial ads Closing interstitial ads. @@ -204,13 +211,6 @@ WARNING: Do not enable new player backgrounds while this is enabled." Select the spoof app version target. Spoof app version target Spoof app version - Chart - Explore - Home - Library - Subscription - Set the start page. - Start page Enable SponsorBlock SponsorBlock is a crowd-sourced system for skipping annoying parts of YouTube videos. diff --git a/src/main/resources/music/startpage/host/values/arrays.xml b/src/main/resources/music/startpage/host/values/arrays.xml index 21a2ff9c7..3f3e14323 100644 --- a/src/main/resources/music/startpage/host/values/arrays.xml +++ b/src/main/resources/music/startpage/host/values/arrays.xml @@ -1,13 +1,13 @@ - - @string/revanced_start_page_entry_chart - @string/revanced_start_page_entry_explore - @string/revanced_start_page_entry_home - @string/revanced_start_page_entry_library - @string/revanced_start_page_entry_subscription + + @string/revanced_change_start_page_entry_chart + @string/revanced_change_start_page_entry_explore + @string/revanced_change_start_page_entry_home + @string/revanced_change_start_page_entry_library + @string/revanced_change_start_page_entry_subscription - + FEmusic_charts FEmusic_explore FEmusic_home