feat(YouTube Music): add support version v6.26.50

This commit is contained in:
inotia00 2023-11-06 17:35:01 +09:00
parent c662cfadd6
commit bba0293460
65 changed files with 138 additions and 143 deletions

View File

@ -51,8 +51,8 @@ Example:
"versions": [ "versions": [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
} }
], ],

View File

@ -31,8 +31,8 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -33,8 +33,8 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -33,8 +33,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.formats.Instruction35c
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -25,8 +25,8 @@ import app.revanced.util.enum.CategoryType
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -28,8 +28,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -21,8 +21,8 @@ import app.revanced.util.enum.CategoryType
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -23,8 +23,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -26,8 +26,8 @@ import app.revanced.util.integrations.Constants.MUSIC_FLYOUT
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -32,8 +32,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -23,8 +23,8 @@ import app.revanced.util.enum.CategoryType
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -30,8 +30,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -23,8 +23,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -18,8 +18,8 @@ import org.w3c.dom.Element
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -23,8 +23,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -16,8 +16,8 @@ import app.revanced.util.resources.IconHelper.customIconMusicAdditional
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -15,8 +15,8 @@ import app.revanced.util.resources.IconHelper.customIconMusic
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -15,8 +15,8 @@ import app.revanced.util.resources.IconHelper.customIconMusic
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -17,8 +17,8 @@ import app.revanced.patcher.patch.options.PatchOption.PatchExtensions.stringPatc
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -32,8 +32,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -27,8 +27,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -28,8 +28,8 @@ import app.revanced.util.integrations.Constants.MUSIC_GENERAL
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -25,8 +25,8 @@ import app.revanced.util.integrations.Constants.MUSIC_GENERAL
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -24,8 +24,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import app.revanced.util.integrations.Constants.MUSIC_COMPONENTS_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -30,8 +30,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -19,8 +19,8 @@ import app.revanced.patches.music.utils.resourceid.SharedResourceIdPatch
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -18,8 +18,8 @@ import app.revanced.patches.music.misc.backgroundplay.fingerprints.BackgroundPla
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -14,8 +14,8 @@ import app.revanced.patcher.patch.annotation.Patch
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -18,8 +18,8 @@ import app.revanced.util.integrations.Constants.MUSIC_MISC_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -17,8 +17,8 @@ import app.revanced.util.enum.CategoryType
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -27,8 +27,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -17,8 +17,8 @@ import app.revanced.patches.music.misc.minimizedplayback.fingerprints.MinimizedP
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -32,8 +32,8 @@ import com.android.tools.smali.dexlib2.iface.reference.Reference
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -26,8 +26,8 @@ import app.revanced.util.resources.ResourceUtils.copyXmlNode
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -19,8 +19,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -17,8 +17,8 @@ import app.revanced.util.resources.ResourceHelper.addTranslations
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -27,8 +27,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -33,8 +33,8 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -32,8 +32,8 @@ import kotlin.properties.Delegates
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -22,8 +22,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -21,8 +21,8 @@ import app.revanced.util.integrations.Constants.MUSIC_PLAYER
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -21,8 +21,8 @@ import app.revanced.util.integrations.Constants.MUSIC_PLAYER
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -25,8 +25,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -23,8 +23,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -42,8 +42,8 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -39,8 +39,8 @@ import com.android.tools.smali.dexlib2.util.MethodUtil
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -26,8 +26,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -17,8 +17,8 @@ import app.revanced.patches.music.utils.fix.androidauto.fingerprints.Certificate
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -31,8 +31,8 @@ import app.revanced.util.microg.MicroGBytecodeHelper
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -23,8 +23,8 @@ import org.w3c.dom.Node
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -32,8 +32,8 @@ import java.nio.file.Paths
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -1,18 +1,14 @@
package app.revanced.patches.music.utils.settings.fingerprints package app.revanced.patches.music.utils.settings.fingerprints
import app.revanced.patcher.fingerprint.MethodFingerprint import app.revanced.patcher.fingerprint.MethodFingerprint
import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
object PreferenceFingerprint : MethodFingerprint( object PreferenceFingerprint : MethodFingerprint(
returnType = "V", returnType = "V",
accessFlags = AccessFlags.PROTECTED.value,
parameters = listOf("Z"), parameters = listOf("Z"),
opcodes = listOf( opcodes = listOf(
Opcode.RETURN_VOID,
Opcode.XOR_INT_LIT8,
Opcode.INVOKE_VIRTUAL,
Opcode.MOVE_RESULT,
Opcode.IF_NE,
Opcode.RETURN_VOID,
Opcode.IGET_OBJECT, Opcode.IGET_OBJECT,
Opcode.INVOKE_VIRTUAL, Opcode.INVOKE_VIRTUAL,
Opcode.MOVE_RESULT_OBJECT, Opcode.MOVE_RESULT_OBJECT,

View File

@ -23,8 +23,8 @@ import app.revanced.util.resources.ResourceUtils.copyResources
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -2,14 +2,13 @@ package app.revanced.patches.music.utils.videotype
import app.revanced.extensions.exception import app.revanced.extensions.exception
import app.revanced.patcher.data.BytecodeContext import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.extensions.InstructionExtensions.addInstructions import app.revanced.patcher.extensions.InstructionExtensions.addInstructionsWithLabels
import app.revanced.patcher.extensions.InstructionExtensions.getInstruction import app.revanced.patcher.extensions.InstructionExtensions.getInstruction
import app.revanced.patcher.extensions.InstructionExtensions.removeInstruction
import app.revanced.patcher.patch.BytecodePatch import app.revanced.patcher.patch.BytecodePatch
import app.revanced.patches.music.utils.videotype.fingerprint.VideoTypeFingerprint import app.revanced.patches.music.utils.videotype.fingerprint.VideoTypeFingerprint
import app.revanced.patches.music.utils.videotype.fingerprint.VideoTypeParentFingerprint import app.revanced.patches.music.utils.videotype.fingerprint.VideoTypeParentFingerprint
import app.revanced.util.integrations.Constants.MUSIC_UTILS_PATH import app.revanced.util.integrations.Constants.MUSIC_UTILS_PATH
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction
@Suppress("unused") @Suppress("unused")
object VideoTypeHookPatch : BytecodePatch( object VideoTypeHookPatch : BytecodePatch(
@ -25,17 +24,18 @@ object VideoTypeHookPatch : BytecodePatch(
) )
}.result?.let { }.result?.let {
it.mutableMethod.apply { it.mutableMethod.apply {
val videoTypeIndex = it.scanResult.patternScanResult!!.endIndex val insertIndex = it.scanResult.patternScanResult!!.startIndex + 3
val videoTypeRegister = val referenceIndex = insertIndex + 1
getInstruction<OneRegisterInstruction>(videoTypeIndex).registerA val referenceInstruction = getInstruction<ReferenceInstruction>(referenceIndex).reference
addInstructions( addInstructionsWithLabels(
videoTypeIndex + 1, """ insertIndex, """
invoke-static {v$videoTypeRegister}, $INTEGRATIONS_CLASS_DESCRIPTOR->setVideoType(Ljava/lang/Enum;)V if-nez p0, :dismiss
return-object v$videoTypeRegister sget-object p0, $referenceInstruction
:dismiss
invoke-static {p0}, $INTEGRATIONS_CLASS_DESCRIPTOR->setVideoType(Ljava/lang/Enum;)V
""" """
) )
removeInstruction(videoTypeIndex)
} }
} ?: throw VideoTypeFingerprint.exception } ?: throw VideoTypeFingerprint.exception
} ?: throw VideoTypeParentFingerprint.exception } ?: throw VideoTypeParentFingerprint.exception

View File

@ -16,7 +16,6 @@ object VideoTypeFingerprint : MethodFingerprint(
Opcode.IF_NEZ, Opcode.IF_NEZ,
Opcode.SGET_OBJECT, Opcode.SGET_OBJECT,
Opcode.GOTO, Opcode.GOTO,
Opcode.SGET_OBJECT, Opcode.SGET_OBJECT
Opcode.RETURN_OBJECT
) )
) )

View File

@ -19,8 +19,8 @@ import app.revanced.util.integrations.Constants.MUSIC_VIDEO_PATH
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
], ],

View File

@ -30,8 +30,8 @@ import com.android.tools.smali.dexlib2.builder.instruction.BuilderInstruction21c
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -29,8 +29,8 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
[ [
"6.15.52", "6.15.52",
"6.20.51", "6.20.51",
"6.23.55", "6.25.53",
"6.25.53" "6.26.50"
] ]
) )
] ]

View File

@ -167,8 +167,8 @@ Note: Disabling the speed overlay does not restore the 'Slide to seek' behavior
<string name="revanced_enable_tablet_navigation_bar_title">Enable tablet navigation bar</string> <string name="revanced_enable_tablet_navigation_bar_title">Enable tablet navigation bar</string>
<string name="revanced_enable_video_codec_summary">Spoof device information to enable video codec.</string> <string name="revanced_enable_video_codec_summary">Spoof device information to enable video codec.</string>
<string name="revanced_enable_video_codec_title">Enable video codec</string> <string name="revanced_enable_video_codec_title">Enable video codec</string>
<string name="revanced_enable_video_codec_type_summary_off">Enable VP9 codec.</string> <string name="revanced_enable_video_codec_type_summary_off">VP9 codec is enabled.</string>
<string name="revanced_enable_video_codec_type_summary_on">Enable HDR codec.</string> <string name="revanced_enable_video_codec_type_summary_on">HDR codec is enabled.</string>
<string name="revanced_enable_video_codec_type_title">Video codec type</string> <string name="revanced_enable_video_codec_type_title">Video codec type</string>
<string name="revanced_enable_wide_search_bar_summary_off">Wide search bar is disabled.</string> <string name="revanced_enable_wide_search_bar_summary_off">Wide search bar is disabled.</string>
<string name="revanced_enable_wide_search_bar_summary_on">Wide search bar is enabled.</string> <string name="revanced_enable_wide_search_bar_summary_on">Wide search bar is enabled.</string>