Compare commits

...

11 Commits

Author SHA1 Message Date
semantic-release-bot
11d6eca36e chore(release): 4.0.0-dev.12 [skip ci]
# [4.0.0-dev.12](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.11...v4.0.0-dev.12) (2024-01-24)

### Features

* **YouTube:** Support version `19.03.35` ([#2640](https://github.com/ReVanced/revanced-patches/issues/2640)) ([eac360e](eac360ee7c))
2024-01-24 13:21:05 +00:00
LisoUseInAIKyrios
eac360ee7c feat(YouTube): Support version 19.03.35 (#2640) 2024-01-24 17:19:02 +04:00
semantic-release-bot
9acf15f571 chore(release): 4.0.0-dev.11 [skip ci]
# [4.0.0-dev.11](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.10...v4.0.0-dev.11) (2024-01-17)

### Features

* **YouTube:** Support version `19.02.34` ([#2627](https://github.com/ReVanced/revanced-patches/issues/2627)) ([126fe48](126fe48ce6))
2024-01-17 20:27:00 +00:00
LisoUseInAIKyrios
126fe48ce6 feat(YouTube): Support version 19.02.34 (#2627) 2024-01-18 00:24:55 +04:00
semantic-release-bot
32d2037083 chore(release): 4.0.0-dev.10 [skip ci]
# [4.0.0-dev.10](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.9...v4.0.0-dev.10) (2024-01-16)

### Features

* **YouTube:** Support versions `18.48.39`, `18.49.37` and `19.01.34` ([#2551](https://github.com/ReVanced/revanced-patches/issues/2551)) ([aca1dd6](aca1dd6074))
2024-01-16 18:56:13 +00:00
oSumAtrIX
aca1dd6074 feat(YouTube): Support versions 18.48.39, 18.49.37 and 19.01.34 (#2551)
Co-authored-by: LisoUseInAIKyrios <118716522+LisoUseInAIKyrios@users.noreply.github.com>
2024-01-16 19:54:06 +01:00
semantic-release-bot
30c6749f61 chore(release): 4.0.0-dev.9 [skip ci]
# [4.0.0-dev.9](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.8...v4.0.0-dev.9) (2024-01-11)

### Bug Fixes

* **YouTube - Enable slide to seek:** Change patch default to excluded and add description disclaimer ([#2610](https://github.com/ReVanced/revanced-patches/issues/2610)) ([08c3079](08c30791ae))
2024-01-11 14:56:11 +00:00
LisoUseInAIKyrios
08c30791ae fix(YouTube - Enable slide to seek): Change patch default to excluded and add description disclaimer (#2610) 2024-01-11 15:54:10 +01:00
semantic-release-bot
002f11a854 chore(release): 4.0.0-dev.8 [skip ci]
# [4.0.0-dev.8](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.7...v4.0.0-dev.8) (2024-01-10)

### Bug Fixes

* **YouTube:** Shorten setting titles to fit on screen ([#2579](https://github.com/ReVanced/revanced-patches/issues/2579)) ([861e9a3](861e9a399e))
2024-01-10 11:28:55 +00:00
KobeW50
861e9a399e fix(YouTube): Shorten setting titles to fit on screen (#2579) 2024-01-10 15:26:24 +04:00
oSumAtrIX
795aee13e4 build: Bump dependencies 2024-01-10 09:33:02 +01:00
79 changed files with 571 additions and 294 deletions

View File

@@ -1,3 +1,38 @@
# [4.0.0-dev.12](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.11...v4.0.0-dev.12) (2024-01-24)
### Features
* **YouTube:** Support version `19.03.35` ([#2640](https://github.com/ReVanced/revanced-patches/issues/2640)) ([ff08f58](https://github.com/ReVanced/revanced-patches/commit/ff08f58ac4ff4d66a8dce599caa1ce47f3366fc6))
# [4.0.0-dev.11](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.10...v4.0.0-dev.11) (2024-01-17)
### Features
* **YouTube:** Support version `19.02.34` ([#2627](https://github.com/ReVanced/revanced-patches/issues/2627)) ([94e08b7](https://github.com/ReVanced/revanced-patches/commit/94e08b74ced394abf9ae7d4fe6355bfe4d0be248))
# [4.0.0-dev.10](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.9...v4.0.0-dev.10) (2024-01-16)
### Features
* **YouTube:** Support versions `18.48.39`, `18.49.37` and `19.01.34` ([#2551](https://github.com/ReVanced/revanced-patches/issues/2551)) ([a938e73](https://github.com/ReVanced/revanced-patches/commit/a938e736fa2aed1792cfdce5656efa15d0791d71))
# [4.0.0-dev.9](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.8...v4.0.0-dev.9) (2024-01-11)
### Bug Fixes
* **YouTube - Enable slide to seek:** Change patch default to excluded and add description disclaimer ([#2610](https://github.com/ReVanced/revanced-patches/issues/2610)) ([2fdc4c2](https://github.com/ReVanced/revanced-patches/commit/2fdc4c23b5f39153ad71071359274c39129d691f))
# [4.0.0-dev.8](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.7...v4.0.0-dev.8) (2024-01-10)
### Bug Fixes
* **YouTube:** Shorten setting titles to fit on screen ([#2579](https://github.com/ReVanced/revanced-patches/issues/2579)) ([b2a5dd3](https://github.com/ReVanced/revanced-patches/commit/b2a5dd3efc39ae8a42159858b9c00b5b2f8655a4))
# [4.0.0-dev.7](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.6...v4.0.0-dev.7) (2024-01-10) # [4.0.0-dev.7](https://github.com/ReVanced/revanced-patches/compare/v4.0.0-dev.6...v4.0.0-dev.7) (2024-01-10)

View File

@@ -1,4 +1,4 @@
org.gradle.parallel = true org.gradle.parallel = true
org.gradle.caching = true org.gradle.caching = true
kotlin.code.style = official kotlin.code.style = official
version = 4.0.0-dev.7 version = 4.0.0-dev.12

View File

@@ -1,5 +1,5 @@
[versions] [versions]
revanced-patcher = "19.1.0" revanced-patcher = "19.2.0"
smali = "3.0.3" smali = "3.0.3"
guava = "33.0.0-jre" guava = "33.0.0-jre"
gson = "2.10.1" gson = "2.10.1"

File diff suppressed because one or more lines are too long

View File

@@ -24,15 +24,18 @@ import com.android.tools.smali.dexlib2.iface.instruction.formats.Instruction35c
], ],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", "com.google.android.youtube", [
[
"18.32.39", "18.32.39",
"18.37.36", "18.37.36",
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -25,8 +25,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -29,8 +29,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -17,15 +17,12 @@ import app.revanced.patches.youtube.video.information.VideoInformationPatch
], ],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", "com.google.android.youtube", [
[ "18.48.39",
"18.32.39", "18.49.37",
"18.37.36", "19.01.34",
"18.38.44", "19.02.39",
"18.43.45", "19.03.35"
"18.44.41",
"18.45.41",
"18.45.43"
] ]
) )
] ]

View File

@@ -21,7 +21,19 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
dependencies = [IntegrationsPatch::class, SettingsPatch::class], dependencies = [IntegrationsPatch::class, SettingsPatch::class],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube" "com.google.android.youtube", [
"18.32.39",
"18.37.36",
"18.38.44",
"18.43.45",
"18.44.41",
"18.45.43",
"18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
]
) )
] ]
) )

View File

@@ -17,15 +17,12 @@ import app.revanced.patches.youtube.video.information.VideoInformationPatch
], ],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", "com.google.android.youtube", [
[ "18.48.39",
"18.32.39", "18.49.37",
"18.37.36", "19.01.34",
"18.38.44", "19.02.39",
"18.43.45", "19.03.35"
"18.44.41",
"18.45.41",
"18.45.43"
] ]
), ),
] ]

View File

@@ -27,8 +27,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -29,8 +29,12 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
[ [
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -17,7 +17,7 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
@Patch( @Patch(
name = "Enable slide to seek", name = "Enable slide to seek",
description = "Adds an option to enable slide to seek instead of playing at 2x speed when pressing and holding in the video player.", description = "Adds an option to enable slide to seek instead of playing at 2x speed when pressing and holding in the video player. Including this patch may cause issues with tapping or double tapping the video player overlay.",
dependencies = [IntegrationsPatch::class, SettingsPatch::class], dependencies = [IntegrationsPatch::class, SettingsPatch::class],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
@@ -25,11 +25,16 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
[ [
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ],
use = false
) )
@Suppress("unused") @Suppress("unused")
object EnableSlideToSeekPatch : BytecodePatch( object EnableSlideToSeekPatch : BytecodePatch(

View File

@@ -1,7 +1,5 @@
package app.revanced.patches.youtube.interaction.swipecontrols package app.revanced.patches.youtube.interaction.swipecontrols
import app.revanced.util.transformMethods
import app.revanced.util.traverseClassHierarchy
import app.revanced.patcher.data.BytecodeContext import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.patch.BytecodePatch import app.revanced.patcher.patch.BytecodePatch
import app.revanced.patcher.patch.annotation.CompatiblePackage import app.revanced.patcher.patch.annotation.CompatiblePackage
@@ -10,7 +8,9 @@ import app.revanced.patcher.util.proxy.mutableTypes.MutableMethod.Companion.toMu
import app.revanced.patches.youtube.interaction.swipecontrols.fingerprints.SwipeControlsHostActivityFingerprint import app.revanced.patches.youtube.interaction.swipecontrols.fingerprints.SwipeControlsHostActivityFingerprint
import app.revanced.patches.youtube.misc.integrations.IntegrationsPatch import app.revanced.patches.youtube.misc.integrations.IntegrationsPatch
import app.revanced.patches.youtube.misc.playertype.PlayerTypeHookPatch import app.revanced.patches.youtube.misc.playertype.PlayerTypeHookPatch
import app.revanced.patches.youtube.shared.fingerprints.WatchWhileActivityFingerprint import app.revanced.patches.youtube.shared.fingerprints.MainActivityFingerprint
import app.revanced.util.transformMethods
import app.revanced.util.traverseClassHierarchy
import com.android.tools.smali.dexlib2.AccessFlags import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.immutable.ImmutableMethod import com.android.tools.smali.dexlib2.immutable.ImmutableMethod
@@ -31,8 +31,12 @@ import com.android.tools.smali.dexlib2.immutable.ImmutableMethod
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]
@@ -40,19 +44,19 @@ import com.android.tools.smali.dexlib2.immutable.ImmutableMethod
@Suppress("unused") @Suppress("unused")
object SwipeControlsBytecodePatch : BytecodePatch( object SwipeControlsBytecodePatch : BytecodePatch(
setOf( setOf(
WatchWhileActivityFingerprint, MainActivityFingerprint,
SwipeControlsHostActivityFingerprint SwipeControlsHostActivityFingerprint
) )
) { ) {
override fun execute(context: BytecodeContext) { override fun execute(context: BytecodeContext) {
val wrapperClass = SwipeControlsHostActivityFingerprint.result!!.mutableClass val wrapperClass = SwipeControlsHostActivityFingerprint.result!!.mutableClass
val targetClass = WatchWhileActivityFingerprint.result!!.mutableClass val targetClass = MainActivityFingerprint.result!!.mutableClass
// inject the wrapper class from integrations into the class hierarchy of WatchWhileActivity // Inject the wrapper class from integrations into the class hierarchy of MainActivity.
wrapperClass.setSuperClass(targetClass.superclass) wrapperClass.setSuperClass(targetClass.superclass)
targetClass.setSuperClass(wrapperClass.type) targetClass.setSuperClass(wrapperClass.type)
// ensure all classes and methods in the hierarchy are non-final, so we can override them in integrations // Ensure all classes and methods in the hierarchy are non-final, so we can override them in integrations.
context.traverseClassHierarchy(targetClass) { context.traverseClassHierarchy(targetClass) {
accessFlags = accessFlags and AccessFlags.FINAL.value.inv() accessFlags = accessFlags and AccessFlags.FINAL.value.inv()
transformMethods { transformMethods {

View File

@@ -29,8 +29,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
], ],

View File

@@ -27,8 +27,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -37,8 +37,12 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -28,8 +28,12 @@ import com.android.tools.smali.dexlib2.Opcode
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -34,8 +34,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -32,8 +32,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.formats.Instruction3rc
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -27,8 +27,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -27,8 +27,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -26,8 +26,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -27,8 +27,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -30,8 +30,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.formats.Instruction21c
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -27,8 +27,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,8 +23,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,8 +23,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -37,8 +37,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]
@@ -97,7 +101,7 @@ object HideLayoutComponentsPatch : BytecodePatch(
"revanced_hide_search_result_recommendations", "revanced_hide_search_result_recommendations",
StringResource( StringResource(
"revanced_hide_search_result_recommendations_title", "revanced_hide_search_result_recommendations_title",
"Hide search result recommendations (e.g People also watched)" "Hide \\\'People also watched\\\' recommendations"
), ),
StringResource( StringResource(
"revanced_hide_search_result_recommendations_summary_on", "revanced_hide_search_result_recommendations_summary_on",

View File

@@ -34,8 +34,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,8 +23,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,8 +23,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -20,15 +20,21 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
SettingsPatch::class SettingsPatch::class
], ],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage("com.google.android.youtube", [ CompatiblePackage(
"18.32.39", "com.google.android.youtube", [
"18.37.36", "18.32.39",
"18.38.44", "18.37.36",
"18.43.45", "18.38.44",
"18.44.41", "18.43.45",
"18.45.41", "18.44.41",
"18.45.43" "18.45.43",
]) "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
]
)
] ]
) )
@Suppress("unused") @Suppress("unused")

View File

@@ -25,8 +25,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -31,8 +31,12 @@ import app.revanced.patches.youtube.shared.fingerprints.SeekbarOnDrawFingerprint
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -35,8 +35,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]
@@ -56,6 +60,8 @@ object HideShortsComponentsPatch : BytecodePatch(
override fun execute(context: BytecodeContext) { override fun execute(context: BytecodeContext) {
// region Hide the Shorts shelf. // region Hide the Shorts shelf.
// This patch point is not present in 19.03.x and greater.
// If 19.02.x and lower is dropped, then this section of code and the fingerprint should be removed.
ReelConstructorFingerprint.result?.let { ReelConstructorFingerprint.result?.let {
it.mutableMethod.apply { it.mutableMethod.apply {
val insertIndex = it.scanResult.patternScanResult!!.startIndex + 2 val insertIndex = it.scanResult.patternScanResult!!.startIndex + 2
@@ -68,7 +74,7 @@ object HideShortsComponentsPatch : BytecodePatch(
"hideShortsShelf" "hideShortsShelf"
) )
} }
} ?: throw ReelConstructorFingerprint.exception } // Do not throw an exception if not resolved.
// endregion // endregion

View File

@@ -97,9 +97,15 @@ object HideShortsComponentsResourcePatch : ResourcePatch() {
) )
) )
fun String.getId() = ResourceMappingPatch.resourceMappings.single { it.name == this }.id ResourceMappingPatch.resourceMappings.find {
it.type == "layout" && it.name == "reel_multiple_items_shelf"
}?.also {
reelMultipleItemShelfId = it.id
}
reelMultipleItemShelfId = "reel_multiple_items_shelf".getId() reelPlayerRightCellButtonHeight =
reelPlayerRightCellButtonHeight = "reel_player_right_cell_button_height".getId() ResourceMappingPatch.resourceMappings.single {
it.type == "dimen" && it.name == "reel_player_right_cell_button_height"
}.id
} }
} }

View File

@@ -1,13 +1,19 @@
package app.revanced.patches.youtube.layout.hide.shorts.fingerprints package app.revanced.patches.youtube.layout.hide.shorts.fingerprints
import app.revanced.patcher.extensions.or import app.revanced.patcher.extensions.or
import app.revanced.patcher.fingerprint.MethodFingerprint
import app.revanced.patches.youtube.layout.hide.shorts.HideShortsComponentsResourcePatch import app.revanced.patches.youtube.layout.hide.shorts.HideShortsComponentsResourcePatch
import app.revanced.util.patch.LiteralValueFingerprint import app.revanced.util.containsWideLiteralInstructionValue
import com.android.tools.smali.dexlib2.AccessFlags import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
internal object ReelConstructorFingerprint : LiteralValueFingerprint( internal object ReelConstructorFingerprint : MethodFingerprint(
accessFlags = AccessFlags.PUBLIC or AccessFlags.CONSTRUCTOR, accessFlags = AccessFlags.PUBLIC or AccessFlags.CONSTRUCTOR,
opcodes = listOf(Opcode.INVOKE_VIRTUAL), opcodes = listOf(Opcode.INVOKE_VIRTUAL),
literalSupplier = { HideShortsComponentsResourcePatch.reelMultipleItemShelfId } customFingerprint = { methodDef, _ ->
// Cannot use LiteralValueFingerprint, because the resource id may not be present.
val reelMultipleItemShelfId = HideShortsComponentsResourcePatch.reelMultipleItemShelfId
reelMultipleItemShelfId != -1L
&& methodDef.containsWideLiteralInstructionValue(reelMultipleItemShelfId)
}
) )

View File

@@ -22,8 +22,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -19,13 +19,16 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.32.39",
"18.37.36", "18.37.36",
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -24,8 +24,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -18,8 +18,12 @@ import org.w3c.dom.Element
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
], ],

View File

@@ -5,7 +5,6 @@ import app.revanced.patcher.extensions.InstructionExtensions.addInstruction
import app.revanced.patcher.extensions.InstructionExtensions.addInstructions import app.revanced.patcher.extensions.InstructionExtensions.addInstructions
import app.revanced.patcher.extensions.InstructionExtensions.addInstructionsWithLabels 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.replaceInstruction
import app.revanced.patcher.fingerprint.MethodFingerprint import app.revanced.patcher.fingerprint.MethodFingerprint
import app.revanced.patcher.patch.BytecodePatch import app.revanced.patcher.patch.BytecodePatch
import app.revanced.patcher.patch.PatchException import app.revanced.patcher.patch.PatchException
@@ -18,7 +17,7 @@ import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.Lik
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RemoveLikeFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RemoveLikeFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureAnimatedTextFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureAnimatedTextFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureStaticLabelFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureStaticLabelFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureTextParentFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberMeasureStaticLabelParentFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberSetterFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberSetterFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberTextViewFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.RollingNumberTextViewFingerprint
import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.ShortsTextViewFingerprint import app.revanced.patches.youtube.layout.returnyoutubedislike.fingerprints.ShortsTextViewFingerprint
@@ -55,11 +54,10 @@ import com.android.tools.smali.dexlib2.iface.reference.TypeReference
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.38.44", "18.49.37",
"18.43.45", "19.01.34",
"18.44.41", "19.02.39",
"18.45.41", "19.03.35"
"18.45.43"
] ]
) )
] ]
@@ -76,7 +74,8 @@ object ReturnYouTubeDislikePatch : BytecodePatch(
DislikeFingerprint, DislikeFingerprint,
RemoveLikeFingerprint, RemoveLikeFingerprint,
RollingNumberSetterFingerprint, RollingNumberSetterFingerprint,
RollingNumberMeasureTextParentFingerprint, RollingNumberMeasureStaticLabelParentFingerprint,
RollingNumberMeasureAnimatedTextFingerprint,
RollingNumberTextViewFingerprint, RollingNumberTextViewFingerprint,
RollingNumberTextViewAnimationUpdateFingerprint RollingNumberTextViewAnimationUpdateFingerprint
) )
@@ -276,37 +275,30 @@ object ReturnYouTubeDislikePatch : BytecodePatch(
// Rolling Number text views use the measured width of the raw string for layout. // Rolling Number text views use the measured width of the raw string for layout.
// Modify the measure text calculation to include the left drawable separator if needed. // Modify the measure text calculation to include the left drawable separator if needed.
RollingNumberMeasureAnimatedTextFingerprint.also { RollingNumberMeasureAnimatedTextFingerprint.result?.also {
if (!it.resolve(context, RollingNumberMeasureTextParentFingerprint.result!!.classDef)) val scanResult = it.scanResult.patternScanResult!!
throw it.exception // Additional check to verify the opcodes are at the start of the method
}.result?.also { if (scanResult.startIndex != 0) throw PatchException("Unexpected opcode location")
val endIndex = scanResult.endIndex
it.mutableMethod.apply { it.mutableMethod.apply {
val returnInstructionIndex = it.scanResult.patternScanResult!!.endIndex val measuredTextWidthRegister = getInstruction<OneRegisterInstruction>(endIndex).registerA
val measuredTextWidthRegister =
getInstruction<OneRegisterInstruction>(returnInstructionIndex).registerA
replaceInstruction( // Replace instruction to preserve control flow label.
returnInstructionIndex,
"invoke-static {p1, v$measuredTextWidthRegister}, $INTEGRATIONS_CLASS_DESCRIPTOR->onRollingNumberMeasured(Ljava/lang/String;F)F"
)
addInstructions( addInstructions(
returnInstructionIndex + 1, endIndex + 1,
"""
move-result v$measuredTextWidthRegister
return v$measuredTextWidthRegister
""" """
invoke-static {p1, v$measuredTextWidthRegister}, $INTEGRATIONS_CLASS_DESCRIPTOR->onRollingNumberMeasured(Ljava/lang/String;F)F
move-result v$measuredTextWidthRegister
"""
) )
} }
} ?: throw RollingNumberMeasureAnimatedTextFingerprint.exception } ?: throw RollingNumberMeasureAnimatedTextFingerprint.exception
// Additional text measurement method. Used if YouTube decides not to animate the likes count // Additional text measurement method. Used if YouTube decides not to animate the likes count
// and sometimes used for initial video load. // and sometimes used for initial video load.
RollingNumberMeasureStaticLabelFingerprint.also { RollingNumberMeasureStaticLabelFingerprint.resolve(context, RollingNumberMeasureStaticLabelParentFingerprint.resultOrThrow().classDef)
if (!it.resolve(context, RollingNumberMeasureTextParentFingerprint.result!!.classDef)) RollingNumberMeasureStaticLabelFingerprint.result?.also {
throw it.exception val measureTextIndex = it.scanResult.patternScanResult!!.startIndex + 1
}.result?.also {
it.mutableMethod.apply { it.mutableMethod.apply {
val measureTextIndex = it.scanResult.patternScanResult!!.startIndex + 1
val freeRegister = getInstruction<TwoRegisterInstruction>(0).registerA val freeRegister = getInstruction<TwoRegisterInstruction>(0).registerA
addInstructions( addInstructions(

View File

@@ -5,19 +5,24 @@ import app.revanced.patcher.fingerprint.MethodFingerprint
import com.android.tools.smali.dexlib2.AccessFlags import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
/**
* Resolves to class found in [RollingNumberMeasureTextParentFingerprint].
*/
internal object RollingNumberMeasureAnimatedTextFingerprint : MethodFingerprint( internal object RollingNumberMeasureAnimatedTextFingerprint : MethodFingerprint(
returnType = "F", returnType = "Lj\$/util/Optional;",
accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL, accessFlags = AccessFlags.PUBLIC or AccessFlags.STATIC,
parameters = listOf("Ljava/lang/String;"), parameters = listOf(
"L",
"Ljava/lang/String;",
"L"
),
opcodes = listOf( opcodes = listOf(
Opcode.INVOKE_VIRTUAL, Opcode.IGET, // First instruction of method
Opcode.IGET_OBJECT,
Opcode.IGET_OBJECT,
Opcode.CONST_HIGH16,
Opcode.INVOKE_STATIC,
Opcode.MOVE_RESULT, Opcode.MOVE_RESULT,
Opcode.ADD_FLOAT_2ADDR, Opcode.CONST_4,
Opcode.ADD_INT_LIT8, Opcode.AGET,
Opcode.GOTO, Opcode.CONST_4,
Opcode.RETURN Opcode.CONST_4, // Measured text width
) )
) )

View File

@@ -6,7 +6,7 @@ import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
/** /**
* Resolves to class found in [RollingNumberMeasureTextParentFingerprint]. * Resolves to class found in [RollingNumberMeasureStaticLabelParentFingerprint].
*/ */
internal object RollingNumberMeasureStaticLabelFingerprint : MethodFingerprint( internal object RollingNumberMeasureStaticLabelFingerprint : MethodFingerprint(
returnType = "F", returnType = "F",

View File

@@ -4,7 +4,7 @@ import app.revanced.patcher.extensions.or
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.AccessFlags
internal object RollingNumberMeasureTextParentFingerprint : MethodFingerprint( internal object RollingNumberMeasureStaticLabelParentFingerprint : MethodFingerprint(
returnType = "Ljava/lang/String;", returnType = "Ljava/lang/String;",
accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL, accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL,
parameters = listOf(), parameters = listOf(),

View File

@@ -26,8 +26,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.37.36", "18.37.36",
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,8 +23,12 @@ import app.revanced.patches.youtube.misc.integrations.IntegrationsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -38,13 +38,11 @@ import com.android.tools.smali.dexlib2.iface.reference.StringReference
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.32.39", "18.48.39",
"18.37.36", "18.49.37",
"18.38.44", "19.01.34",
"18.43.45", "19.02.39",
"18.44.41", "19.03.35"
"18.45.41",
"18.45.43"
] ]
) )
], ],

View File

@@ -28,8 +28,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -24,8 +24,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -32,8 +32,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
) )
) )
] ]

View File

@@ -35,8 +35,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -40,8 +40,12 @@ import com.android.tools.smali.dexlib2.immutable.ImmutableMethod
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -10,7 +10,7 @@ import app.revanced.patcher.patch.annotation.Patch
import app.revanced.patches.shared.settings.preference.impl.StringResource import app.revanced.patches.shared.settings.preference.impl.StringResource
import app.revanced.patches.shared.settings.preference.impl.SwitchPreference import app.revanced.patches.shared.settings.preference.impl.SwitchPreference
import app.revanced.patches.youtube.misc.settings.SettingsPatch import app.revanced.patches.youtube.misc.settings.SettingsPatch
import app.revanced.patches.youtube.shared.fingerprints.WatchWhileActivityFingerprint import app.revanced.patches.youtube.shared.fingerprints.MainActivityFingerprint
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
@Patch( @Patch(
@@ -21,15 +21,15 @@ import com.android.tools.smali.dexlib2.Opcode
) )
@Suppress("unused") @Suppress("unused")
object AnnouncementsPatch : BytecodePatch( object AnnouncementsPatch : BytecodePatch(
setOf(WatchWhileActivityFingerprint) setOf(MainActivityFingerprint)
) { ) {
private const val INTEGRATIONS_CLASS_DESCRIPTOR = private const val INTEGRATIONS_CLASS_DESCRIPTOR =
"Lapp/revanced/integrations/youtube/patches/announcements/AnnouncementsPatch;" "Lapp/revanced/integrations/youtube/patches/announcements/AnnouncementsPatch;"
override fun execute(context: BytecodeContext) { override fun execute(context: BytecodeContext) {
val onCreateMethod = WatchWhileActivityFingerprint.result?.let { val onCreateMethod = MainActivityFingerprint.result?.let {
it.mutableClass.methods.find { method -> method.name == "onCreate" } it.mutableClass.methods.find { method -> method.name == "onCreate" }
} ?: throw WatchWhileActivityFingerprint.exception } ?: throw MainActivityFingerprint.exception
val superCallIndex = onCreateMethod.getInstructions().indexOfFirst { it.opcode == Opcode.INVOKE_SUPER_RANGE } val superCallIndex = onCreateMethod.getInstructions().indexOfFirst { it.opcode == Opcode.INVOKE_SUPER_RANGE }
@@ -43,7 +43,7 @@ object AnnouncementsPatch : BytecodePatch(
"revanced_announcements", "revanced_announcements",
StringResource( StringResource(
"revanced_announcements_title", "revanced_announcements_title",
"Show announcements from ReVanced" "Show ReVanced announcements"
), ),
StringResource( StringResource(
"revanced_announcements_summary_on", "revanced_announcements_summary_on",

View File

@@ -28,8 +28,12 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -23,12 +23,17 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]
) )
@Suppress("unused")
object SpoofDeviceDimensionsPatch : BytecodePatch( object SpoofDeviceDimensionsPatch : BytecodePatch(
setOf(DeviceDimensionsModelToStringFingerprint) setOf(DeviceDimensionsModelToStringFingerprint)
) { ) {

View File

@@ -1,6 +1,5 @@
package app.revanced.patches.youtube.misc.fix.backtoexitgesture package app.revanced.patches.youtube.misc.fix.backtoexitgesture
import app.revanced.util.exception
import app.revanced.patcher.data.BytecodeContext import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.extensions.InstructionExtensions.addInstruction import app.revanced.patcher.extensions.InstructionExtensions.addInstruction
import app.revanced.patcher.fingerprint.MethodFingerprint import app.revanced.patcher.fingerprint.MethodFingerprint
@@ -10,6 +9,7 @@ import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.OnBa
import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewScrollingFingerprint import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewScrollingFingerprint
import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewTopScrollingFingerprint import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewTopScrollingFingerprint
import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewTopScrollingParentFingerprint import app.revanced.patches.youtube.misc.fix.backtoexitgesture.fingerprints.RecyclerViewTopScrollingParentFingerprint
import app.revanced.util.exception
@Patch(description = "Fixes the swipe back to exit gesture.") @Patch(description = "Fixes the swipe back to exit gesture.")
@Suppress("unused") @Suppress("unused")
@@ -37,7 +37,7 @@ internal object FixBackToExitGesturePatch : BytecodePatch(
methodName = "onScrollingViews" methodName = "onScrollingViews"
), ),
OnBackPressedFingerprint to IntegrationsMethod( OnBackPressedFingerprint to IntegrationsMethod(
"p0", "onBackPressed", "Lcom/google/android/apps/youtube/app/watchwhile/WatchWhileActivity;" "p0", "onBackPressed", "Landroid/app/Activity;"
) )
).forEach { (fingerprint, target) -> fingerprint.injectCall(target) } ).forEach { (fingerprint, target) -> fingerprint.injectCall(target) }
} }

View File

@@ -12,7 +12,9 @@ internal object OnBackPressedFingerprint : MethodFingerprint(
Opcode.RETURN_VOID Opcode.RETURN_VOID
), ),
customFingerprint = { methodDef, _ -> customFingerprint = { methodDef, _ ->
methodDef.definingClass.endsWith("WatchWhileActivity;") (methodDef.definingClass.endsWith("MainActivity;") ||
// Old versions of YouTube called this class "WatchWhileActivity" instead.
methodDef.definingClass.endsWith("WatchWhileActivity;"))
&& methodDef.name == "onBackPressed" && methodDef.name == "onBackPressed"
} }
) )

View File

@@ -10,22 +10,18 @@ import app.revanced.patcher.patch.annotation.Patch
import app.revanced.patches.youtube.misc.fix.playback.fingerprints.UserAgentHeaderBuilderFingerprint import app.revanced.patches.youtube.misc.fix.playback.fingerprints.UserAgentHeaderBuilderFingerprint
import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
@Patch( @Patch(
name = "Client spoof", name = "Client spoof",
description = "Adds options to spoof the client to allow video playback.", description = "Adds options to spoof the client to allow video playback.",
dependencies = [SpoofSignaturePatch::class], dependencies = [SpoofSignaturePatch::class],
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", "com.google.android.youtube", [
[ "18.48.39",
"18.32.39", "18.49.37",
"18.37.36", "19.01.34",
"18.38.44", "19.02.39",
"18.43.45", "19.03.35"
"18.44.41",
"18.45.41",
"18.45.43"
] ]
) )
] ]

View File

@@ -33,13 +33,11 @@ object GmsCoreSupportPatch : AbstractGmsCoreSupportPatch(
compatiblePackages = setOf( compatiblePackages = setOf(
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", setOf( "com.google.android.youtube", setOf(
"18.32.39", "18.48.39",
"18.37.36", "18.49.37",
"18.38.44", "19.01.34",
"18.43.45", "19.02.39",
"18.44.41", "19.03.35"
"18.45.41",
"18.45.43"
) )
) )
), ),

View File

@@ -25,12 +25,17 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
[ [
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]
) )
@Suppress("unused")
object BypassURLRedirectsPatch : BytecodePatch( object BypassURLRedirectsPatch : BytecodePatch(
setOf(ABUriParserFingerprint, HTTPUriParserFingerprint) setOf(ABUriParserFingerprint, HTTPUriParserFingerprint)
) { ) {

View File

@@ -28,8 +28,12 @@ import com.android.tools.smali.dexlib2.iface.reference.StringReference
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -34,13 +34,11 @@ import com.android.tools.smali.dexlib2.iface.reference.MethodReference
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", "com.google.android.youtube",
[ [
"18.32.39", "18.48.39",
"18.37.36", "18.49.37",
"18.38.44", "19.01.34",
"18.43.45", "19.02.39",
"18.44.41", "19.03.35"
"18.45.41",
"18.45.43"
] ]
) )
] ]

View File

@@ -30,8 +30,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
[ [
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -4,10 +4,12 @@ import app.revanced.patcher.extensions.or
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.AccessFlags
internal object WatchWhileActivityFingerprint : MethodFingerprint( internal object MainActivityFingerprint : MethodFingerprint(
accessFlags = AccessFlags.PUBLIC or AccessFlags.CONSTRUCTOR, accessFlags = AccessFlags.PUBLIC or AccessFlags.CONSTRUCTOR,
parameters = listOf(), parameters = listOf(),
customFingerprint = { methodDef, _ -> customFingerprint = { methodDef, _ ->
methodDef.definingClass.endsWith("WatchWhileActivity;") methodDef.definingClass.endsWith("MainActivity;")
// Old versions of YouTube called this class "WatchWhileActivity" instead.
|| methodDef.definingClass.endsWith("WatchWhileActivity;")
} }
) )

View File

@@ -26,8 +26,12 @@ import com.android.tools.smali.dexlib2.iface.reference.FieldReference
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]

View File

@@ -1,6 +1,5 @@
package app.revanced.patches.youtube.video.information package app.revanced.patches.youtube.video.information
import app.revanced.util.exception
import app.revanced.patcher.data.BytecodeContext import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.extensions.InstructionExtensions.addInstruction import app.revanced.patcher.extensions.InstructionExtensions.addInstruction
import app.revanced.patcher.extensions.InstructionExtensions.addInstructions import app.revanced.patcher.extensions.InstructionExtensions.addInstructions
@@ -14,13 +13,14 @@ import app.revanced.patches.youtube.misc.integrations.IntegrationsPatch
import app.revanced.patches.youtube.video.information.fingerprints.* import app.revanced.patches.youtube.video.information.fingerprints.*
import app.revanced.patches.youtube.video.playerresponse.PlayerResponseMethodHookPatch import app.revanced.patches.youtube.video.playerresponse.PlayerResponseMethodHookPatch
import app.revanced.patches.youtube.video.videoid.VideoIdPatch import app.revanced.patches.youtube.video.videoid.VideoIdPatch
import app.revanced.util.exception
import com.android.tools.smali.dexlib2.AccessFlags import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
import com.android.tools.smali.dexlib2.builder.BuilderInstruction import com.android.tools.smali.dexlib2.builder.BuilderInstruction
import com.android.tools.smali.dexlib2.builder.MutableMethodImplementation import com.android.tools.smali.dexlib2.builder.MutableMethodImplementation
import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction import com.android.tools.smali.dexlib2.iface.instruction.ReferenceInstruction
import com.android.tools.smali.dexlib2.iface.instruction.TwoRegisterInstruction
import com.android.tools.smali.dexlib2.immutable.ImmutableMethod import com.android.tools.smali.dexlib2.immutable.ImmutableMethod
import com.android.tools.smali.dexlib2.immutable.ImmutableMethodParameter import com.android.tools.smali.dexlib2.immutable.ImmutableMethodParameter
import com.android.tools.smali.dexlib2.util.MethodUtil import com.android.tools.smali.dexlib2.util.MethodUtil
@@ -135,23 +135,24 @@ object VideoInformationPatch : BytecodePatch(
*/ */
videoTimeHook(INTEGRATIONS_CLASS_DESCRIPTOR, "setVideoTime") videoTimeHook(INTEGRATIONS_CLASS_DESCRIPTOR, "setVideoTime")
/* /*
* Hook the user playback speed selection * Hook the user playback speed selection
*/ */
OnPlaybackSpeedItemClickFingerprint.result?.apply { OnPlaybackSpeedItemClickFingerprint.result?.mutableMethod?.apply {
speedSelectionInsertMethod = mutableMethod speedSelectionInsertMethod = this
speedSelectionInsertIndex = scanResult.patternScanResult!!.startIndex - 3 val speedSelectionMethodInstructions = this.implementation!!.instructions
val speedSelectionValueInstructionIndex = speedSelectionMethodInstructions.indexOfFirst {
it.opcode == Opcode.IGET
}
speedSelectionValueRegister = speedSelectionValueRegister =
mutableMethod.getInstruction<FiveRegisterInstruction>(speedSelectionInsertIndex).registerD getInstruction<TwoRegisterInstruction>(speedSelectionValueInstructionIndex).registerA
setPlaybackSpeedClassFieldReference =
val speedSelectionMethodInstructions = mutableMethod.implementation!!.instructions getInstruction<ReferenceInstruction>(speedSelectionValueInstructionIndex + 1).reference.toString()
setPlaybackSpeedMethodReference =
getInstruction<ReferenceInstruction>(speedSelectionValueInstructionIndex + 2).reference.toString()
setPlaybackSpeedContainerClassFieldReference = setPlaybackSpeedContainerClassFieldReference =
getReference(speedSelectionMethodInstructions, -1, Opcode.IF_EQZ) getReference(speedSelectionMethodInstructions, -1, Opcode.IF_EQZ)
setPlaybackSpeedClassFieldReference = speedSelectionInsertIndex = speedSelectionValueInstructionIndex + 1
getReference(speedSelectionMethodInstructions, 1, Opcode.IGET)
setPlaybackSpeedMethodReference =
getReference(speedSelectionMethodInstructions, 2, Opcode.IGET)
} ?: throw OnPlaybackSpeedItemClickFingerprint.exception } ?: throw OnPlaybackSpeedItemClickFingerprint.exception
userSelectedPlaybackSpeedHook(INTEGRATIONS_CLASS_DESCRIPTOR, "userSelectedPlaybackSpeed") userSelectedPlaybackSpeedHook(INTEGRATIONS_CLASS_DESCRIPTOR, "userSelectedPlaybackSpeed")

View File

@@ -2,18 +2,19 @@ package app.revanced.patches.youtube.video.information.fingerprints
import app.revanced.patcher.extensions.or import app.revanced.patcher.extensions.or
import app.revanced.patcher.fingerprint.MethodFingerprint import app.revanced.patcher.fingerprint.MethodFingerprint
import app.revanced.util.getReference
import com.android.tools.smali.dexlib2.AccessFlags import com.android.tools.smali.dexlib2.AccessFlags
import com.android.tools.smali.dexlib2.Opcode import com.android.tools.smali.dexlib2.Opcode
import com.android.tools.smali.dexlib2.iface.reference.FieldReference
internal object OnPlaybackSpeedItemClickFingerprint : MethodFingerprint( internal object OnPlaybackSpeedItemClickFingerprint : MethodFingerprint(
accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL, accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL,
returnType = "V", returnType = "V",
parameters = listOf("L", "L", "I", "J"), parameters = listOf("L", "L", "I", "J"),
customFingerprint = { methodDef, _ -> methodDef.name == "onItemClick" }, customFingerprint = { methodDef, _ ->
opcodes = listOf( methodDef.name == "onItemClick" && methodDef.implementation?.instructions?.find {
Opcode.MOVE_RESULT_OBJECT, it.opcode == Opcode.IGET_OBJECT &&
Opcode.INVOKE_VIRTUAL, it.getReference<FieldReference>()!!.type == "Lcom/google/android/libraries/youtube/innertube/model/player/PlayerResponseModel;"
Opcode.INVOKE_VIRTUAL, } != null
Opcode.RETURN_VOID }
)
) )

View File

@@ -18,29 +18,44 @@ object PlayerResponseMethodHookPatch :
BytecodePatch(setOf(PlayerParameterBuilderFingerprint)), BytecodePatch(setOf(PlayerParameterBuilderFingerprint)),
Closeable, Closeable,
MutableSet<PlayerResponseMethodHookPatch.Hook> by mutableSetOf() { MutableSet<PlayerResponseMethodHookPatch.Hook> by mutableSetOf() {
private const val VIDEO_ID_PARAMETER = 1
private const val IS_SHORT_AND_OPENING_OR_PLAYING_PARAMETER = 11 // Parameter numbers of the patched method.
private const val PROTO_BUFFER_PARAMETER_PARAMETER = 3 private const val PARAMETER_VIDEO_ID = 1
private const val PARAMETER_PROTO_BUFFER = 3
private const val PARAMETER_IS_SHORT_AND_OPENING_OR_PLAYING = 11
// Temporary 4-bit registers used to pass the parameters to integrations.
private const val REGISTER_VIDEO_ID = 0
private const val REGISTER_PROTO_BUFFER = 1
private const val REGISTER_IS_SHORT_AND_OPENING_OR_PLAYING = 2
private lateinit var playerResponseMethod: MutableMethod private lateinit var playerResponseMethod: MutableMethod
private var numberOfInstructionsAdded = 0
override fun execute(context: BytecodeContext) { override fun execute(context: BytecodeContext) {
playerResponseMethod = PlayerParameterBuilderFingerprint.result?.mutableMethod playerResponseMethod = PlayerParameterBuilderFingerprint.result?.mutableMethod
?: throw PlayerParameterBuilderFingerprint.exception ?: throw PlayerParameterBuilderFingerprint.exception
} }
override fun close() { override fun close() {
fun hookVideoId(hook: Hook) = playerResponseMethod.addInstruction( fun hookVideoId(hook: Hook) {
0, "invoke-static {p$VIDEO_ID_PARAMETER, p$IS_SHORT_AND_OPENING_OR_PLAYING_PARAMETER}, $hook" playerResponseMethod.addInstruction(
) 0, "invoke-static {v$REGISTER_VIDEO_ID, v$REGISTER_IS_SHORT_AND_OPENING_OR_PLAYING}, $hook"
)
numberOfInstructionsAdded++
}
fun hookProtoBufferParameter(hook: Hook) = playerResponseMethod.addInstructions( fun hookProtoBufferParameter(hook: Hook) {
0, playerResponseMethod.addInstructions(
0,
"""
invoke-static {v$REGISTER_PROTO_BUFFER, v$REGISTER_IS_SHORT_AND_OPENING_OR_PLAYING}, $hook
move-result-object v$REGISTER_PROTO_BUFFER
""" """
invoke-static {p$PROTO_BUFFER_PARAMETER_PARAMETER, p$IS_SHORT_AND_OPENING_OR_PLAYING_PARAMETER}, $hook )
move-result-object p$PROTO_BUFFER_PARAMETER_PARAMETER numberOfInstructionsAdded += 2
""" }
)
// Reverse the order in order to preserve insertion order of the hooks. // Reverse the order in order to preserve insertion order of the hooks.
val beforeVideoIdHooks = filterIsInstance<Hook.ProtoBufferParameterBeforeVideoId>().asReversed() val beforeVideoIdHooks = filterIsInstance<Hook.ProtoBufferParameterBeforeVideoId>().asReversed()
@@ -51,6 +66,23 @@ object PlayerResponseMethodHookPatch :
afterVideoIdHooks.forEach(::hookProtoBufferParameter) afterVideoIdHooks.forEach(::hookProtoBufferParameter)
videoIdHooks.forEach(::hookVideoId) videoIdHooks.forEach(::hookVideoId)
beforeVideoIdHooks.forEach(::hookProtoBufferParameter) beforeVideoIdHooks.forEach(::hookProtoBufferParameter)
// On some app targets the method has too many registers pushing the parameters past v15.
// Move the parameters to 4-bit registers so they can be passed to integrations.
playerResponseMethod.addInstructions(
0, """
move-object/from16 v$REGISTER_VIDEO_ID, p$PARAMETER_VIDEO_ID
move-object/from16 v$REGISTER_PROTO_BUFFER, p$PARAMETER_PROTO_BUFFER
move/from16 v$REGISTER_IS_SHORT_AND_OPENING_OR_PLAYING, p$PARAMETER_IS_SHORT_AND_OPENING_OR_PLAYING
""",
)
numberOfInstructionsAdded += 3
// Move the modified register back.
playerResponseMethod.addInstruction(
numberOfInstructionsAdded,
"move-object/from16 p$PARAMETER_PROTO_BUFFER, v$REGISTER_PROTO_BUFFER"
)
} }
internal abstract class Hook(private val methodDescriptor: String) { internal abstract class Hook(private val methodDescriptor: String) {

View File

@@ -31,13 +31,11 @@ import com.android.tools.smali.dexlib2.iface.reference.FieldReference
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.32.39", "18.48.39",
"18.37.36", "18.49.37",
"18.38.44", "19.01.34",
"18.43.45", "19.02.39",
"18.44.41", "19.03.35"
"18.45.41",
"18.45.43"
] ]
) )
] ]

View File

@@ -14,13 +14,11 @@ import app.revanced.patches.youtube.video.speed.remember.RememberPlaybackSpeedPa
compatiblePackages = [ compatiblePackages = [
CompatiblePackage( CompatiblePackage(
"com.google.android.youtube", [ "com.google.android.youtube", [
"18.32.39", "18.48.39",
"18.37.36", "18.49.37",
"18.38.44", "19.01.34",
"18.43.45", "19.02.39",
"18.44.41", "19.03.35"
"18.45.41",
"18.45.43"
] ]
) )
] ]

View File

@@ -29,7 +29,13 @@ import com.android.tools.smali.dexlib2.immutable.ImmutableField
@Patch( @Patch(
description = "Adds custom playback speed options.", description = "Adds custom playback speed options.",
dependencies = [IntegrationsPatch::class, LithoFilterPatch::class, SettingsPatch::class, RecyclerViewTreeHookPatch::class] dependencies = [
IntegrationsPatch::class,
LithoFilterPatch::class,
SettingsPatch::class,
RecyclerViewTreeHookPatch::class,
CustomPlaybackSpeedResourcePatch::class
]
) )
object CustomPlaybackSpeedPatch : BytecodePatch( object CustomPlaybackSpeedPatch : BytecodePatch(
setOf( setOf(

View File

@@ -0,0 +1,15 @@
package app.revanced.patches.youtube.video.speed.custom
import app.revanced.patcher.data.ResourceContext
import app.revanced.patcher.patch.ResourcePatch
import app.revanced.patches.shared.mapping.misc.ResourceMappingPatch
internal object CustomPlaybackSpeedResourcePatch : ResourcePatch() {
var speedUnavailableId: Long = -1
override fun execute(context: ResourceContext) {
speedUnavailableId = ResourceMappingPatch.resourceMappings.single {
it.type == "string" && it.name == "varispeed_unavailable_message"
}.id
}
}

View File

@@ -1,7 +1,10 @@
package app.revanced.patches.youtube.video.speed.custom.fingerprints package app.revanced.patches.youtube.video.speed.custom.fingerprints
import app.revanced.patcher.fingerprint.MethodFingerprint import app.revanced.patches.youtube.video.speed.custom.CustomPlaybackSpeedResourcePatch
import app.revanced.util.patch.LiteralValueFingerprint
internal object ShowOldPlaybackSpeedMenuFingerprint : MethodFingerprint( internal object ShowOldPlaybackSpeedMenuFingerprint : LiteralValueFingerprint(
strings = listOf("PLAYBACK_RATE_MENU_BOTTOM_SHEET_FRAGMENT") literalSupplier = {
CustomPlaybackSpeedResourcePatch.speedUnavailableId
}
) )

View File

@@ -1,6 +1,5 @@
package app.revanced.patches.youtube.video.videoid package app.revanced.patches.youtube.video.videoid
import app.revanced.util.exception
import app.revanced.patcher.data.BytecodeContext import app.revanced.patcher.data.BytecodeContext
import app.revanced.patcher.extensions.InstructionExtensions.addInstruction import app.revanced.patcher.extensions.InstructionExtensions.addInstruction
import app.revanced.patcher.extensions.InstructionExtensions.getInstruction import app.revanced.patcher.extensions.InstructionExtensions.getInstruction
@@ -13,6 +12,7 @@ import app.revanced.patches.youtube.misc.playertype.PlayerTypeHookPatch
import app.revanced.patches.youtube.video.playerresponse.PlayerResponseMethodHookPatch import app.revanced.patches.youtube.video.playerresponse.PlayerResponseMethodHookPatch
import app.revanced.patches.youtube.video.videoid.fingerprint.VideoIdFingerprint import app.revanced.patches.youtube.video.videoid.fingerprint.VideoIdFingerprint
import app.revanced.patches.youtube.video.videoid.fingerprint.VideoIdFingerprintBackgroundPlay import app.revanced.patches.youtube.video.videoid.fingerprint.VideoIdFingerprintBackgroundPlay
import app.revanced.util.exception
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
@Patch( @Patch(
@@ -49,7 +49,7 @@ object VideoIdPatch : BytecodePatch(
consumer(it, insertIndex, videoIdRegister) consumer(it, insertIndex, videoIdRegister)
} }
} ?: throw VideoIdFingerprint.exception } ?: throw exception
VideoIdFingerprint.setFields { method, index, register -> VideoIdFingerprint.setFields { method, index, register ->
videoIdMethod = method videoIdMethod = method

View File

@@ -10,19 +10,13 @@ internal object VideoIdFingerprint : MethodFingerprint(
accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL, accessFlags = AccessFlags.PUBLIC or AccessFlags.FINAL,
parameters = listOf("L"), parameters = listOf("L"),
opcodes = listOf( opcodes = listOf(
Opcode.MOVE_RESULT_OBJECT,
Opcode.IF_EQZ,
Opcode.INVOKE_VIRTUAL,
Opcode.MOVE_RESULT_OBJECT,
Opcode.INVOKE_INTERFACE,
Opcode.MOVE_RESULT_OBJECT, Opcode.MOVE_RESULT_OBJECT,
Opcode.IF_EQZ, Opcode.IF_EQZ,
Opcode.IGET_OBJECT, Opcode.IGET_OBJECT,
Opcode.INVOKE_VIRTUAL, Opcode.IGET_OBJECT,
Opcode.MOVE_RESULT_OBJECT,
Opcode.INVOKE_INTERFACE, Opcode.INVOKE_INTERFACE,
Opcode.MOVE_RESULT_OBJECT, Opcode.MOVE_RESULT_OBJECT,
Opcode.INVOKE_INTERFACE, Opcode.INVOKE_INTERFACE,
Opcode.MOVE_RESULT_OBJECT Opcode.MOVE_RESULT_OBJECT,
) )
) )

View File

@@ -10,18 +10,10 @@ internal object VideoIdFingerprintBackgroundPlay : MethodFingerprint(
accessFlags = AccessFlags.DECLARED_SYNCHRONIZED or AccessFlags.FINAL or AccessFlags.PUBLIC, accessFlags = AccessFlags.DECLARED_SYNCHRONIZED or AccessFlags.FINAL or AccessFlags.PUBLIC,
parameters = listOf("L"), parameters = listOf("L"),
opcodes = listOf( opcodes = listOf(
Opcode.MONITOR_EXIT,
Opcode.RETURN_VOID,
Opcode.INVOKE_VIRTUAL,
Opcode.MOVE_RESULT_OBJECT,
Opcode.NEW_ARRAY,
Opcode.SGET_OBJECT,
Opcode.APUT_OBJECT,
Opcode.INVOKE_VIRTUAL, Opcode.INVOKE_VIRTUAL,
Opcode.MOVE_RESULT, Opcode.MOVE_RESULT,
Opcode.IF_EQZ, Opcode.IF_EQZ,
Opcode.INVOKE_VIRTUAL, Opcode.IGET_OBJECT,
Opcode.MOVE_RESULT_OBJECT,
Opcode.IF_EQZ, Opcode.IF_EQZ,
Opcode.INVOKE_INTERFACE, Opcode.INVOKE_INTERFACE,
Opcode.MOVE_RESULT_OBJECT, Opcode.MOVE_RESULT_OBJECT,

View File

@@ -30,8 +30,12 @@ import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
"18.38.44", "18.38.44",
"18.43.45", "18.43.45",
"18.44.41", "18.44.41",
"18.45.41", "18.45.43",
"18.45.43" "18.48.39",
"18.49.37",
"19.01.34",
"19.02.39",
"19.03.35"
] ]
) )
] ]