finish merge
This commit is contained in:
parent
4a73671262
commit
ecda492866
5 changed files with 10 additions and 10 deletions
|
|
@ -7,13 +7,13 @@ import com.android.tools.smali.dexlib2.Opcode
|
||||||
/**
|
/**
|
||||||
* Matches the class found in [energyConfigToStringFingerprint].
|
* Matches the class found in [energyConfigToStringFingerprint].
|
||||||
*/
|
*/
|
||||||
internal val initializeEnergyConfigFingerprint = fingerprint {
|
internal val initializeEnergyConfigFingerprint by fingerprint {
|
||||||
accessFlags(AccessFlags.PUBLIC, AccessFlags.CONSTRUCTOR)
|
accessFlags(AccessFlags.PUBLIC, AccessFlags.CONSTRUCTOR)
|
||||||
opcodes(Opcode.RETURN_VOID)
|
opcodes(Opcode.RETURN_VOID)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Class name currently is not obfuscated but it may be in the future.
|
// Class name currently is not obfuscated but it may be in the future.
|
||||||
internal val energyConfigToStringFingerprint = fingerprint {
|
internal val energyConfigToStringFingerprint by fingerprint {
|
||||||
parameters()
|
parameters()
|
||||||
returns("Ljava/lang/String;")
|
returns("Ljava/lang/String;")
|
||||||
strings("EnergyConfig(", "maxEnergy=") // Partial string matches.
|
strings("EnergyConfig(", "maxEnergy=") // Partial string matches.
|
||||||
|
|
|
||||||
|
|
@ -5,12 +5,12 @@ import app.revanced.patcher.fingerprint
|
||||||
import app.revanced.patcher.patch.BytecodePatchContext
|
import app.revanced.patcher.patch.BytecodePatchContext
|
||||||
import com.android.tools.smali.dexlib2.AccessFlags
|
import com.android.tools.smali.dexlib2.AccessFlags
|
||||||
|
|
||||||
internal val initializeNavigationButtonsListFingerprint = fingerprint {
|
internal val initializeNavigationButtonsListFingerprint by fingerprint {
|
||||||
accessFlags(AccessFlags.PUBLIC, AccessFlags.FINAL)
|
accessFlags(AccessFlags.PUBLIC, AccessFlags.FINAL)
|
||||||
parameters("Lcom/instagram/common/session/UserSession;", "Z")
|
parameters("Lcom/instagram/common/session/UserSession;", "Z")
|
||||||
returns("Ljava/util/List;")
|
returns("Ljava/util/List;")
|
||||||
}
|
}
|
||||||
|
|
||||||
private val navigationButtonsEnumClassDef = fingerprint {
|
internal val navigationButtonsEnumClassDef by fingerprint {
|
||||||
strings("FEED", "fragment_feed", "SEARCH", "fragment_search")
|
strings("FEED", "fragment_feed", "SEARCH", "fragment_search")
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -63,7 +63,7 @@ val hideNavigationButtonsPatch = bytecodePatch(
|
||||||
with(navigationButtonsEnumInitFingerprint.method) {
|
with(navigationButtonsEnumInitFingerprint.method) {
|
||||||
enumNameField = indexOfFirstInstructionOrThrow {
|
enumNameField = indexOfFirstInstructionOrThrow {
|
||||||
opcode == Opcode.IPUT_OBJECT &&
|
opcode == Opcode.IPUT_OBJECT &&
|
||||||
(this as TwoRegisterInstruction).registerA == 2 // The p2 register
|
(this as TwoRegisterInstruction).registerA == 2 // p2 register.
|
||||||
}.let {
|
}.let {
|
||||||
getInstruction(it).getReference<FieldReference>()!!.name
|
getInstruction(it).getReference<FieldReference>()!!.name
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -8,8 +8,8 @@ import app.revanced.patches.all.misc.resources.addResourcesPatch
|
||||||
import app.revanced.patches.music.misc.extension.sharedExtensionPatch
|
import app.revanced.patches.music.misc.extension.sharedExtensionPatch
|
||||||
import app.revanced.patches.music.misc.settings.PreferenceScreen
|
import app.revanced.patches.music.misc.settings.PreferenceScreen
|
||||||
import app.revanced.patches.music.misc.settings.settingsPatch
|
import app.revanced.patches.music.misc.settings.settingsPatch
|
||||||
import app.revanced.patches.shared.misc.mapping.get
|
import app.revanced.patches.shared.misc.mapping.ResourceType
|
||||||
import app.revanced.patches.shared.misc.mapping.resourceMappings
|
import app.revanced.patches.shared.misc.mapping.getResourceId
|
||||||
import app.revanced.patches.shared.misc.settings.preference.SwitchPreference
|
import app.revanced.patches.shared.misc.settings.preference.SwitchPreference
|
||||||
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
import com.android.tools.smali.dexlib2.iface.instruction.OneRegisterInstruction
|
||||||
|
|
||||||
|
|
@ -37,14 +37,14 @@ val hideCategoryBar = bytecodePatch(
|
||||||
)
|
)
|
||||||
|
|
||||||
execute {
|
execute {
|
||||||
chipCloud = resourceMappings["layout", "chip_cloud"]
|
|
||||||
|
|
||||||
addResources("music", "layout.compactheader.hideCategoryBar")
|
addResources("music", "layout.compactheader.hideCategoryBar")
|
||||||
|
|
||||||
PreferenceScreen.GENERAL.addPreferences(
|
PreferenceScreen.GENERAL.addPreferences(
|
||||||
SwitchPreference("revanced_music_hide_category_bar"),
|
SwitchPreference("revanced_music_hide_category_bar"),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
chipCloud = getResourceId(ResourceType.LAYOUT, "chip_cloud")
|
||||||
|
|
||||||
chipCloudFingerprint.method.apply {
|
chipCloudFingerprint.method.apply {
|
||||||
val targetIndex = chipCloudFingerprint.patternMatch!!.endIndex
|
val targetIndex = chipCloudFingerprint.patternMatch!!.endIndex
|
||||||
val targetRegister = getInstruction<OneRegisterInstruction>(targetIndex).registerA
|
val targetRegister = getInstruction<OneRegisterInstruction>(targetIndex).registerA
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import app.revanced.patcher.fingerprint
|
||||||
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 val urlShorteningFingerprint = fingerprint {
|
internal val urlShorteningFingerprint by fingerprint {
|
||||||
accessFlags(AccessFlags.PUBLIC, AccessFlags.STATIC, AccessFlags.FINAL)
|
accessFlags(AccessFlags.PUBLIC, AccessFlags.STATIC, AccessFlags.FINAL)
|
||||||
returns("LX/")
|
returns("LX/")
|
||||||
parameters(
|
parameters(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue