https://bugs.kde.org/show_bug.cgi?id=403806

--- Comment #6 from Martin Flöser <mgraess...@kde.org> ---
Now I'm in front of a keyboard and I can explain in more detail.

On Wayland touch and mouse are different concepts. The mouse cursor - unlike on
X11 - does not warp to the position where you touched. Given that alone a mouse
click emulation through touch events simply doesn't make sense in the
compositor. It would make sense if and only if the application indicates that
it doesn't support touch events. But all applications do indicate that they
support touch.

For the compositor this means the application is able to handle touch events
just fine and to provide useful interactions. A compositor cannot know:
 * whether the application uses long press to emulate right click mouse
behavior
 * whether the application does nothing on long press
 * whether there is a specific action for long press

For example QtQuick Controls 2 ToolTip suggests in the documentation to use a
long press to trigger tooltips which otherwise are shown on mouse hover - see:
https://doc.qt.io/qt-5/qml-qtquick-controls2-tooltip.html

Such functionality instantly gets broken when the compositor starts to steal
the long press. We would have to steal it as otherwise two actions would be
triggered: the one on long press and the right click emulation.

Furthermore also in future a gesture system would not be possible to support
this due to the separation of touch and mouse in Wayland. This is also kept in
KWin and we cannot "just" emit a right mouse button. In Wayland speak we would
have to focus the surface, warp the pointer and send a button down and up. This
would instantly trigger KWin internal functionality such as closing the virtual
keyboard on mouse interaction or showing the mouse cursor again which gets
hidden on touch events.

Overall this is really not a functionality belonging in the compositor. You
might find more luck with toolkits, but I doubt they would implement such
behavior.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to