feat(YouTube Music): Support version 7.03
(#3272)
This commit is contained in:
parent
fcd7e94c1b
commit
d1ceca3998
|
@ -11,7 +11,18 @@ import app.revanced.util.exception
|
||||||
|
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Hide music video ads",
|
name = "Hide music video ads",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
],
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object HideMusicVideoAds : BytecodePatch(
|
object HideMusicVideoAds : BytecodePatch(
|
||||||
|
|
|
@ -11,7 +11,18 @@ import com.android.tools.smali.dexlib2.Opcode
|
||||||
|
|
||||||
@Patch(
|
@Patch(
|
||||||
description = "Adds more audio codec options. The new audio codecs usually result in better audio quality.",
|
description = "Adds more audio codec options. The new audio codecs usually result in better audio quality.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Deprecated("This patch is no longer needed as the feature is now enabled by default.")
|
@Deprecated("This patch is no longer needed as the feature is now enabled by default.")
|
||||||
object CodecsUnlockPatch : BytecodePatch(
|
object CodecsUnlockPatch : BytecodePatch(
|
||||||
|
|
|
@ -11,7 +11,18 @@ import app.revanced.util.exception
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Enable exclusive audio playback",
|
name = "Enable exclusive audio playback",
|
||||||
description = "Enables the option to play audio without video.",
|
description = "Enables the option to play audio without video.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object EnableExclusiveAudioPlayback : BytecodePatch(
|
object EnableExclusiveAudioPlayback : BytecodePatch(
|
||||||
|
|
|
@ -13,7 +13,18 @@ import app.revanced.patches.music.interaction.permanentrepeat.fingerprints.Repea
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Permanent repeat",
|
name = "Permanent repeat",
|
||||||
description = "Permanently remember your repeating preference even if the playlist ends or another track is played.",
|
description = "Permanently remember your repeating preference even if the playlist ends or another track is played.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
],
|
||||||
use = false
|
use = false
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
|
@ -23,7 +34,7 @@ object PermanentRepeatPatch : BytecodePatch(
|
||||||
override fun execute(context: BytecodeContext) {
|
override fun execute(context: BytecodeContext) {
|
||||||
RepeatTrackFingerprint.result?.let {
|
RepeatTrackFingerprint.result?.let {
|
||||||
val startIndex = it.scanResult.patternScanResult!!.endIndex
|
val startIndex = it.scanResult.patternScanResult!!.endIndex
|
||||||
val repeatIndex = startIndex + 3
|
val repeatIndex = startIndex + 1
|
||||||
|
|
||||||
it.mutableMethod.apply {
|
it.mutableMethod.apply {
|
||||||
addInstructionsWithLabels(
|
addInstructionsWithLabels(
|
||||||
|
|
|
@ -6,17 +6,16 @@ import com.android.tools.smali.dexlib2.AccessFlags
|
||||||
import com.android.tools.smali.dexlib2.Opcode
|
import com.android.tools.smali.dexlib2.Opcode
|
||||||
|
|
||||||
internal object RepeatTrackFingerprint : MethodFingerprint(
|
internal object RepeatTrackFingerprint : MethodFingerprint(
|
||||||
"V",
|
returnType = "V",
|
||||||
AccessFlags.PUBLIC or AccessFlags.FINAL,
|
accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL,
|
||||||
listOf("L", "L"),
|
parameters = listOf("L", "L"),
|
||||||
listOf(
|
opcodes = listOf(
|
||||||
Opcode.CHECK_CAST,
|
|
||||||
Opcode.INVOKE_INTERFACE,
|
|
||||||
Opcode.IGET_OBJECT,
|
Opcode.IGET_OBJECT,
|
||||||
Opcode.IGET_OBJECT,
|
Opcode.IGET_OBJECT,
|
||||||
Opcode.SGET_OBJECT,
|
Opcode.SGET_OBJECT,
|
||||||
Opcode.INVOKE_VIRTUAL,
|
Opcode.INVOKE_VIRTUAL,
|
||||||
Opcode.MOVE_RESULT,
|
Opcode.MOVE_RESULT,
|
||||||
Opcode.IF_NEZ
|
Opcode.IF_NEZ
|
||||||
)
|
),
|
||||||
|
strings = listOf("w_st")
|
||||||
)
|
)
|
||||||
|
|
|
@ -12,7 +12,18 @@ import app.revanced.util.exception
|
||||||
name = "Permanent shuffle",
|
name = "Permanent shuffle",
|
||||||
description = "Permanently remember your shuffle preference " +
|
description = "Permanently remember your shuffle preference " +
|
||||||
"even if the playlist ends or another track is played.",
|
"even if the playlist ends or another track is played.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
],
|
||||||
use = false,
|
use = false,
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
|
|
|
@ -13,7 +13,18 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Hide category bar",
|
name = "Hide category bar",
|
||||||
description = "Hides the category bar at the top of the homepage.",
|
description = "Hides the category bar at the top of the homepage.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
],
|
||||||
use = false,
|
use = false,
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
|
|
|
@ -13,7 +13,18 @@ import app.revanced.util.exception
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Minimized playback",
|
name = "Minimized playback",
|
||||||
description = "Unlocks options for picture-in-picture and background playback.",
|
description = "Unlocks options for picture-in-picture and background playback.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object MinimizedPlaybackPatch : BytecodePatch(
|
object MinimizedPlaybackPatch : BytecodePatch(
|
||||||
|
|
|
@ -16,7 +16,18 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Hide 'Get Music Premium' label",
|
name = "Hide 'Get Music Premium' label",
|
||||||
description = "Hides the \"Get Music Premium\" label from the account menu and settings.",
|
description = "Hides the \"Get Music Premium\" label from the account menu and settings.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object HideGetPremiumPatch : BytecodePatch(
|
object HideGetPremiumPatch : BytecodePatch(
|
||||||
|
|
|
@ -22,7 +22,18 @@ import com.android.tools.smali.dexlib2.iface.reference.FieldReference
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Remove upgrade button",
|
name = "Remove upgrade button",
|
||||||
description = "Removes the upgrade tab from the pivot bar.",
|
description = "Removes the upgrade tab from the pivot bar.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")],
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object RemoveUpgradeButtonPatch : BytecodePatch(
|
object RemoveUpgradeButtonPatch : BytecodePatch(
|
||||||
|
|
|
@ -12,7 +12,18 @@ import app.revanced.patches.music.misc.androidauto.fingerprints.CheckCertificate
|
||||||
@Patch(
|
@Patch(
|
||||||
name = "Bypass certificate checks",
|
name = "Bypass certificate checks",
|
||||||
description = "Bypasses certificate checks which prevent YouTube Music from working on Android Auto.",
|
description = "Bypasses certificate checks which prevent YouTube Music from working on Android Auto.",
|
||||||
compatiblePackages = [CompatiblePackage("com.google.android.apps.youtube.music")]
|
compatiblePackages = [
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
[
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
]
|
||||||
)
|
)
|
||||||
@Suppress("unused")
|
@Suppress("unused")
|
||||||
object BypassCertificateChecksPatch : BytecodePatch(setOf(CheckCertificateFingerprint)) {
|
object BypassCertificateChecksPatch : BytecodePatch(setOf(CheckCertificateFingerprint)) {
|
||||||
|
|
|
@ -23,7 +23,18 @@ object GmsCoreSupportPatch : BaseGmsCoreSupportPatch(
|
||||||
mainActivityOnCreateFingerprint = MusicActivityOnCreateFingerprint,
|
mainActivityOnCreateFingerprint = MusicActivityOnCreateFingerprint,
|
||||||
integrationsPatchDependency = IntegrationsPatch::class,
|
integrationsPatchDependency = IntegrationsPatch::class,
|
||||||
gmsCoreSupportResourcePatch = GmsCoreSupportResourcePatch,
|
gmsCoreSupportResourcePatch = GmsCoreSupportResourcePatch,
|
||||||
compatiblePackages = setOf(CompatiblePackage("com.google.android.apps.youtube.music")),
|
compatiblePackages = setOf(
|
||||||
|
CompatiblePackage(
|
||||||
|
"com.google.android.apps.youtube.music",
|
||||||
|
setOf(
|
||||||
|
"6.45.54",
|
||||||
|
"6.51.53",
|
||||||
|
"7.01.53",
|
||||||
|
"7.02.52",
|
||||||
|
"7.03.52",
|
||||||
|
)
|
||||||
|
)
|
||||||
|
),
|
||||||
fingerprints = setOf(
|
fingerprints = setOf(
|
||||||
ServiceCheckFingerprint,
|
ServiceCheckFingerprint,
|
||||||
GooglePlayUtilityFingerprint,
|
GooglePlayUtilityFingerprint,
|
||||||
|
|
Loading…
Reference in a new issue