mirror of
https://github.com/ReVanced/revanced-patches.git
synced 2026-01-19 17:13:59 +00:00
finish merge
This commit is contained in:
@@ -2,22 +2,13 @@
|
||||
package app.revanced.patches.instagram.hide.navigation
|
||||
|
||||
import app.revanced.patcher.fingerprint
|
||||
import app.revanced.patcher.patch.BytecodePatchContext
|
||||
|
||||
internal val initializeNavigationButtonsListFingerprint = fingerprint {
|
||||
strings("Nav3")
|
||||
parameters("Lcom/instagram/common/session/UserSession;", "Z")
|
||||
internal val initializeNavigationButtonsListFingerprint by fingerprint {
|
||||
returns("Ljava/util/List;")
|
||||
parameters("Lcom/instagram/common/session/UserSession;", "Z")
|
||||
strings("Nav3")
|
||||
}
|
||||
|
||||
private val navigationButtonsEnumClassDef by fingerprint {
|
||||
internal val navigationButtonsEnumClassDef by fingerprint {
|
||||
strings("FEED", "fragment_feed", "SEARCH", "fragment_search")
|
||||
}
|
||||
|
||||
context(BytecodePatchContext)
|
||||
internal val navigationButtonsEnumInitFingerprint get() = fingerprint {
|
||||
custom { method, classDef ->
|
||||
method.name == "<init>"
|
||||
&& classDef == navigationButtonsEnumClassDef.classDef
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package app.revanced.patches.instagram.hide.navigation
|
||||
|
||||
import app.revanced.patcher.extensions.InstructionExtensions.getInstruction
|
||||
import app.revanced.patcher.fingerprint
|
||||
import app.revanced.patcher.patch.booleanOption
|
||||
import app.revanced.patcher.patch.bytecodePatch
|
||||
import app.revanced.util.addInstructionsAtControlFlowLabel
|
||||
@@ -45,9 +46,17 @@ val hideNavigationButtonsPatch = bytecodePatch(
|
||||
)
|
||||
}
|
||||
|
||||
val enumNameField: String
|
||||
|
||||
// Get the field name which contains the name of the enum for the navigation button ("fragment_clips", "fragment_share", ...)
|
||||
// Get the field name which contains the name of the enum for the navigation button
|
||||
// ("fragment_clips", "fragment_share", ...)
|
||||
val navigationButtonsEnumInitFingerprint by fingerprint {
|
||||
custom { method, classDef ->
|
||||
method.name == "<init>"
|
||||
&& classDef == navigationButtonsEnumClassDef.classDef
|
||||
}
|
||||
}
|
||||
|
||||
val enumNameField: String
|
||||
with(navigationButtonsEnumInitFingerprint.method) {
|
||||
enumNameField = indexOfFirstInstructionOrThrow {
|
||||
opcode == Opcode.IPUT_OBJECT &&
|
||||
|
||||
@@ -4,7 +4,7 @@ import app.revanced.patcher.fingerprint
|
||||
|
||||
internal const val YOUTUBE_MUSIC_MAIN_ACTIVITY_CLASS_TYPE = "Lcom/google/android/apps/youtube/music/activities/MusicActivity;"
|
||||
|
||||
internal val mainActivityOnCreateFingerprint = fingerprint {
|
||||
internal val mainActivityOnCreateFingerprint by fingerprint {
|
||||
returns("V")
|
||||
parameters("Landroid/os/Bundle;")
|
||||
custom { method, classDef ->
|
||||
|
||||
@@ -3,7 +3,7 @@ package app.revanced.patches.youtube.video.codecs
|
||||
import app.revanced.patcher.fingerprint
|
||||
import com.android.tools.smali.dexlib2.AccessFlags
|
||||
|
||||
internal val vp9CapabilityFingerprint = fingerprint {
|
||||
internal val vp9CapabilityFingerprint by fingerprint {
|
||||
accessFlags(AccessFlags.PUBLIC, AccessFlags.FINAL)
|
||||
returns("Z")
|
||||
strings(
|
||||
|
||||
Reference in New Issue
Block a user