godot/platform/x11
Pedro J. Estébanez de9d40a953 Implement universal translation of touch to mouse
Now generating mouse events from touch is optional (on by default) and it's performed by `InputDefault` instead of having each OS abstraction doing it. (*)

The translation algorithm waits for a touch index to be pressed and tracks it translating its events to mouse events until it is raised, while ignoring other pointers.

Furthermore, to avoid an stuck "touch mouse", since not all platforms may report touches raised when the window is unfocused, it checks if touches are still down by the time it's focused again and if so it resets the state of the emulated mouse.

*: In the case of Windows, since it already provides touch-to-mouse translation by itself, "echo" mouse events are filtered out to have it working like the rest.

On X11 a little hack has been needed to avoid a case of a spurious mouse motion event that is generated during touch interaction.

Plus: Improve/fix tracking of current mouse position.

** Summary of changes to settings: **

- `display/window/handheld/emulate_touchscreen` becomes `input/pointing_devices/emulate_touch_from_mouse`
- New setting: `input/pointing_devices/emulate_mouse_from_touch`
2018-04-30 19:03:38 +02:00
..
export Add missing copyright headers and fix formatting 2018-01-05 01:22:23 +01:00
context_gl_x11.cpp Explicitly set OpenGL profile to core (X11, Windows). 2018-03-06 15:53:30 +02:00
context_gl_x11.h add GLES 2 renderer for 2D 2018-03-01 15:12:30 +01:00
crash_handler_x11.cpp Fix server build on FreeBSD 2018-03-01 02:16:52 +01:00
crash_handler_x11.h Add missing copyright headers and fix formatting 2018-01-05 01:22:23 +01:00
detect.py Added new audio device functions to set/get the audio device 2018-03-26 17:41:05 -03:00
godot_x11.cpp Add missing copyright headers and fix formatting 2018-01-05 01:22:23 +01:00
joypad_linux.cpp Update copyright statements to 2018 2018-01-01 14:40:47 +01:00
joypad_linux.h Update copyright statements to 2018 2018-01-01 14:40:47 +01:00
key_mapping_x11.cpp Add missing copyright headers and fix formatting 2018-01-05 01:22:23 +01:00
key_mapping_x11.h Add missing copyright headers and fix formatting 2018-01-05 01:22:23 +01:00
logo.png Fixed iCCp chunk in pngs 2016-06-22 21:13:29 +02:00
os_x11.cpp Implement universal translation of touch to mouse 2018-04-30 19:03:38 +02:00
os_x11.h Implement universal translation of touch to mouse 2018-04-30 19:03:38 +02:00
platform_config.h add GLES 2 renderer for 2D 2018-03-01 15:12:30 +01:00
power_x11.cpp Update copyright statements to 2018 2018-01-01 14:40:47 +01:00
power_x11.h Update copyright statements to 2018 2018-01-01 14:40:47 +01:00
SCsub PEP3101 applied with changing old type string formatting as new ones 2018-02-14 19:29:25 +03:00