mirror of
https://github.com/inotia00/revanced-patches.git
synced 2025-05-09 19:14:37 +02:00
chore: lint code
This commit is contained in:
parent
bc48f2b1a6
commit
20389d549a
@ -376,7 +376,9 @@ object ToolBarComponentsPatch : BaseBytecodePatch(
|
|||||||
opcode == Opcode.INVOKE_VIRTUAL
|
opcode == Opcode.INVOKE_VIRTUAL
|
||||||
&& getReference<MethodReference>()?.name == "setImageDrawable"
|
&& getReference<MethodReference>()?.name == "setImageDrawable"
|
||||||
}.forEach { insertIndex ->
|
}.forEach { insertIndex ->
|
||||||
val (viewRegister, drawableRegister) = getInstruction<FiveRegisterInstruction>(insertIndex).let {
|
val (viewRegister, drawableRegister) = getInstruction<FiveRegisterInstruction>(
|
||||||
|
insertIndex
|
||||||
|
).let {
|
||||||
Pair(it.registerC, it.registerD)
|
Pair(it.registerC, it.registerD)
|
||||||
}
|
}
|
||||||
replaceInstruction(
|
replaceInstruction(
|
||||||
|
@ -93,8 +93,10 @@ object PlayerFlyoutMenuPatch : BaseBytecodePatch(
|
|||||||
// region patch for hide '1080p Premium' label
|
// region patch for hide '1080p Premium' label
|
||||||
|
|
||||||
VideoQualityArrayFingerprint.resultOrThrow().mutableMethod.apply {
|
VideoQualityArrayFingerprint.resultOrThrow().mutableMethod.apply {
|
||||||
val qualityLabelIndex = VideoQualityArrayFingerprint.indexOfQualityLabelInstruction(this) + 1
|
val qualityLabelIndex =
|
||||||
val qualityLabelRegister = getInstruction<OneRegisterInstruction>(qualityLabelIndex).registerA
|
VideoQualityArrayFingerprint.indexOfQualityLabelInstruction(this) + 1
|
||||||
|
val qualityLabelRegister =
|
||||||
|
getInstruction<OneRegisterInstruction>(qualityLabelIndex).registerA
|
||||||
val jumpIndex = indexOfFirstInstructionReversedOrThrow(qualityLabelIndex) {
|
val jumpIndex = indexOfFirstInstructionReversedOrThrow(qualityLabelIndex) {
|
||||||
opcode == Opcode.INVOKE_INTERFACE &&
|
opcode == Opcode.INVOKE_INTERFACE &&
|
||||||
getReference<MethodReference>()?.name == "hasNext"
|
getReference<MethodReference>()?.name == "hasNext"
|
||||||
|
@ -68,7 +68,10 @@ object ReturnYouTubeDislikeShortsPatch : BytecodePatch(
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (SettingsPatch.upward1834) {
|
if (SettingsPatch.upward1834) {
|
||||||
TextComponentPatch.hookSpannableString(INTEGRATIONS_RYD_CLASS_DESCRIPTOR, "onCharSequenceLoaded")
|
TextComponentPatch.hookSpannableString(
|
||||||
|
INTEGRATIONS_RYD_CLASS_DESCRIPTOR,
|
||||||
|
"onCharSequenceLoaded"
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,7 +32,8 @@ internal object VideoIdFingerprint : MethodFingerprint(
|
|||||||
return@custom false
|
return@custom false
|
||||||
}
|
}
|
||||||
|
|
||||||
val reference = (instructions.elementAt(instructionCount - 2) as? ReferenceInstruction)?.reference.toString()
|
val reference =
|
||||||
|
(instructions.elementAt(instructionCount - 2) as? ReferenceInstruction)?.reference.toString()
|
||||||
if (reference != "Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;") {
|
if (reference != "Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;") {
|
||||||
return@custom false
|
return@custom false
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user