mpv/input
nanahi 092f556898 input: centralize VO dragging
Currently, VO dragging logic is hardcoded into each VO, where a left mouse
button down event unconditionally begins dragging if the VO dragging test
passes. This method is extremely unflexible as the VO has no knowledge of
what is happening in the input system: while begin dragging with the second
click of a doubleclick is undesired, it cannot determine whether a click
is a double click or not because it's determined by the input system.

The better way to do it is to handle it somewhere in the downstream
consumers of the events instead, as they have more information to make
this decision. The input system is the perfect place for this as the logic
for checking doubleclick already exists. So just issue a begin-vo-dragging
command if it detects a left mouse button down which isn't also a
doubleclick in this case, and delete all hardcoded VO dragging logic
in win32, x11, and wayland.

Note that this solution hardcodes left mouse button down for now, but
because the VO dragging is now centralized, it's possible to make more
improvements, such as a deadzone mechanism to fix the conflict with
MBTN_LEFT mouse bind.
2024-03-01 18:25:12 +01:00
..
cmd.c command: don't hardcode commands list to be repeatable 2021-08-17 22:45:39 +03:00
cmd.h player/command: add ability to scale overlay 2023-12-08 13:37:26 +01:00
event.c input: add insert-next support for drag-and-drop 2024-02-26 02:03:21 +00:00
event.h input: add insert-next support for drag-and-drop 2024-02-26 02:03:21 +00:00
input.c input: centralize VO dragging 2024-03-01 18:25:12 +01:00
input.h command: add load-input-conf 2024-02-04 15:12:02 +00:00
ipc-dummy.c scripting: add a way to run sub processes as "scripts" 2020-02-19 22:18:15 +01:00
ipc-unix.c mp_thread: prefer tracking threads with id 2023-11-05 17:36:17 +00:00
ipc-win.c win32: don't jump over variable init with goto 2023-11-18 23:55:28 +00:00
ipc.c json: unify json_parse depth to MAX_JSON_DEPTH=50 2023-07-08 11:36:15 +02:00
keycodes.c input: add missing forward media key 2023-12-06 11:07:37 +01:00
keycodes.h input: add missing forward media key 2023-12-06 11:07:37 +01:00
meson.build build: remove outdated generated directory 2023-07-31 19:00:06 +00:00
sdl_gamepad.c sdl_gamepad: add version check for SDL_HINT_JOYSTICK_THREAD 2023-11-24 14:27:56 +01:00