Skip to content

Commit

Permalink
feat(YouTube - Disable precise seeking gesture): Use better patch name
Browse files Browse the repository at this point in the history
The new name now is taken from what YouTube names this feature.
  • Loading branch information
oSumAtrIX committed Oct 25, 2023
1 parent e97e0e6 commit 88cce59
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ import app.revanced.patches.youtube.misc.settings.SettingsPatch
import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction

@Patch(
name = "Disable fine scrubbing gesture",
description = "Disables gesture that shows the fine scrubbing overlay when swiping up on the seekbar.",
name = "Disable precise seeking gesture",
description = "Disables the gesture that is used to seek precisely when swiping up on the seekbar.",
dependencies = [IntegrationsPatch::class, SettingsPatch::class],
compatiblePackages = [
CompatiblePackage(
Expand All @@ -30,20 +30,20 @@ import com.android.tools.smali.dexlib2.iface.instruction.FiveRegisterInstruction
]
)
@Suppress("unused")
object DisableFineScrubbingGesturePatch : BytecodePatch(
object DisablePreciseSeekingGesturePatch : BytecodePatch(
setOf(IsSwipingUpFingerprint)
) {
private const val INTEGRATIONS_METHOD_DESCRIPTOR =
"Lapp/revanced/integrations/patches/DisableFineScrubbingGesturePatch;->" +
"Lapp/revanced/integrations/patches/DisablePreciseSeekingGesturePatch;->" +
"disableGesture(Landroid/view/VelocityTracker;Landroid/view/MotionEvent;)V"

override fun execute(context: BytecodeContext) {
SettingsPatch.PreferenceScreen.INTERACTIONS.addPreferences(
SwitchPreference(
"revanced_disable_fine_scrubbing_gesture",
StringResource("revanced_disable_fine_scrubbing_gesture_title", "Disable fine scrubbing gesture"),
StringResource("revanced_disable_fine_scrubbing_gesture_summary_on", "Gesture is disabled"),
StringResource("revanced_disable_fine_scrubbing_gesture_summary_off", "Gesture is enabled"),
"revanced_disable_precise_seeking_gesture",
StringResource("revanced_disable_precise_seeking_gesture_title", "Disable precise seeking gesture"),
StringResource("revanced_disable_precise_seeking_gesture_summary_on", "Gesture is disabled"),
StringResource("revanced_disable_precise_seeking_gesture_summary_off", "Gesture is enabled"),
)
)

Expand Down

0 comments on commit 88cce59

Please sign in to comment.