-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
input: implement VO dragging deadzone #14251
Conversation
Not supported anymore.
Will be used for the VO dragging deadzone.
The stored mouse position mouse_vo_x/y are scaled (currently only for vo_xv), but the position equality check compares between raw position and scaled position. Fix this by storing and checking the raw position instead. The raw position is useful for the next commit.
Download the artifacts for this pull request: |
bf671e5
to
e85928a
Compare
This adds the --input-dragging-deadzone option, which adds a deadzone for the built-in VO deagging. This prevents accidental VO dragging.
Currently, the built-in VO dragging conflicts with the MBTN_LEFT binding, so the binding is activated even though the VO dragging begins. Fix this by releasing the currently down command so that MBTN_LEFT can be bound to a useful action (such as play/pause).
This adds the --input-builtin-dragging option, which allows the built-in dragging behavior to be disabled. This allows scripts to implement custom dragging behavior with left button down events and begin-vo-dragging command, which could only be done for other mouse buttons before.
This prevents doubleclick from activation if a second mouse click comes quickly after a click which begins dragging.
e85928a
to
e72273e
Compare
It breaks OSC seekbar mouse dragging, both osc.lua uosc and mpv-osc-modern are affected. |
Should be fixed by #14301. |
Why conflict with MBTN_LEFT script binding. mp.add_forced_key_binding('MBTN_LEFT', 'MBTN_LEFT', function() mp.commandv('cycle', 'pause') end) |
There is a bug with key bindings registered by scripts which are incorrectly triggered if the command is canceled. #14311 fixes this.
|
This PR fixes several problems with VO dragging:
--input-dragging-deadzone
option, which adds a deadzone for the built-in VO dragging.MBTN_LEFT
binding.Fixes #7563.
Fixes #13225.
Fixes #13958.
Fixes #14248.