Discussion:
D17369: Add touch support to x11 windowed platform
Martin Flöser
2018-12-05 18:13:49 UTC
Permalink
graesslin created this revision.
graesslin added a reviewer: KWin.
Herald added a project: KWin.
Herald added a subscriber: kwin.
graesslin requested review of this revision.

REVISION SUMMARY
This change inits XInput extension, listens for touch events and
forwards them to our platform API. Thus touch events are forwarded on a
nested wayland session on X11.

Please note that I only tested this change on Xwayland.

TEST PLAN
Run nested kwin_wayland with two outputs and looked into debug console

REPOSITORY
R108 KWin

BRANCH
x11-nested-touch

REVISION DETAIL
https://phabricator.kde.org/D17369

AFFECTED FILES
plugins/platforms/x11/windowed/CMakeLists.txt
plugins/platforms/x11/windowed/x11windowed_backend.cpp
plugins/platforms/x11/windowed/x11windowed_backend.h

To: graesslin, #kwin
Cc: kwin, mkulinski, ragreen, jackyalcine, Pitel, iodelay, bwowk, ZrenBot, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart
Vlad Zagorodniy
2018-12-05 18:27:21 UTC
Permalink
zzag added inline comments.

INLINE COMMENTS
x11windowed_backend.cpp:145
+ m_minorVersion = minor;
+ m_hasXInput = m_majorVersion >=2 && m_minorVersion >= 2;
+#endif
Shouldn't it be just m_hasXInput = true?
x11windowed_backend.cpp:232
+ XISelectEvents(m_display, window, evmasks, 1);
+#endif
+}
Missing Q_UNUSED.

REPOSITORY
R108 KWin

REVISION DETAIL
https://phabricator.kde.org/D17369

To: graesslin, #kwin
Cc: zzag, kwin, mkulinski, ragreen, jackyalcine, Pitel, iodelay, bwowk, ZrenBot, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart
Martin Flöser
2018-12-05 20:07:05 UTC
Permalink
graesslin added inline comments.

INLINE COMMENTS
zzag wrote in x11windowed_backend.cpp:145
Shouldn't it be just m_hasXInput = true?
No, that was on purpose. It's the minimum version supporting touch.

REPOSITORY
R108 KWin

REVISION DETAIL
https://phabricator.kde.org/D17369

To: graesslin, #kwin
Cc: zzag, kwin, mkulinski, ragreen, jackyalcine, Pitel, iodelay, bwowk, ZrenBot, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart
Martin Flöser
2018-12-05 20:35:14 UTC
Permalink
graesslin updated this revision to Diff 46917.
graesslin added a comment.


Q_UNUSED

REPOSITORY
R108 KWin

CHANGES SINCE LAST UPDATE
https://phabricator.kde.org/D17369?vs=46911&id=46917

BRANCH
x11-nested-touch

REVISION DETAIL
https://phabricator.kde.org/D17369

AFFECTED FILES
plugins/platforms/x11/windowed/CMakeLists.txt
plugins/platforms/x11/windowed/x11windowed_backend.cpp
plugins/platforms/x11/windowed/x11windowed_backend.h

To: graesslin, #kwin
Cc: zzag, kwin, mkulinski, ragreen, jackyalcine, Pitel, iodelay, bwowk, ZrenBot, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas, apol, mart
Loading...