mirror of
https://github.com/revanced/revanced-integrations.git
synced 2025-01-04 00:55:49 +01:00
feat(YouTube - Disable precise seeking gesture): Hide "pull up" label that shows up when swiping (#696)
This commit is contained in:
parent
ce9e986755
commit
0b9afd022d
@ -1,20 +1,10 @@
|
|||||||
package app.revanced.integrations.youtube.patches;
|
package app.revanced.integrations.youtube.patches;
|
||||||
|
|
||||||
import android.view.MotionEvent;
|
|
||||||
import android.view.VelocityTracker;
|
|
||||||
|
|
||||||
import app.revanced.integrations.youtube.settings.Settings;
|
import app.revanced.integrations.youtube.settings.Settings;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public final class DisablePreciseSeekingGesturePatch {
|
public final class DisablePreciseSeekingGesturePatch {
|
||||||
/**
|
public static boolean isGestureDisabled() {
|
||||||
* Disables the gesture that is used to seek precisely.
|
return Settings.DISABLE_PRECISE_SEEKING_GESTURE.get();
|
||||||
* @param tracker The velocity tracker that is used to determine the gesture.
|
|
||||||
* @param event The motion event that is used to determine the gesture.
|
|
||||||
*/
|
|
||||||
public static void disableGesture(VelocityTracker tracker, MotionEvent event) {
|
|
||||||
if (Settings.DISABLE_PRECISE_SEEKING_GESTURE.get()) return;
|
|
||||||
|
|
||||||
tracker.addMovement(event);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user