[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-panel-devel
Subject: D9516: [libinput] Add support for switch devices and events
From: Martin_Flöser <noreply () phabricator ! kde ! org>
Date: 2017-12-27 17:02:57
Message-ID: 20171227170257.68569.14B2C554FDF52696 () phabricator ! kde ! org
[Download RAW message or body]
graesslin created this revision.
graesslin added reviewers: KWin, Plasma.
Restricted Application added a project: KWin.
Restricted Application added subscribers: kwin, plasma-devel.
Restricted Application edited projects, added Plasma; removed KWin.
REVISION SUMMARY
This change adds support for the switch devices introduces with libinput
1.7 (lid) and 1.9 (tablet mode). So far it's not yet used internally in
KWin, but only exposed through the Device and Events.
As KWin currently only requires libinput 1.5 and we are rather late in
the release cycle the new functionality is ifdef'ed. The requirement
will be raised once master is 5.13. It is already available on
build.kde.org, but e.g. Neon only has 1.6.
The switch events are interesting as they report whether the lid is
closed (might be interesting for e.g. powerdevil) and whether a
convertible is in tablet mode (supported for e.g. Lenovo Yogas with
recent kernel). This can be used by KWin internally to enable/disable
the virtual keyboard. And can be exposed globally to switch to Plasma
Mobile shell in future.
TEST PLAN
Only through test case as my Lenovo Yoga uses Neon which has a
too old libinput
REPOSITORY
R108 KWin
BRANCH
libinput-switch
REVISION DETAIL
https://phabricator.kde.org/D9516
AFFECTED FILES
CMakeLists.txt
autotests/libinput/CMakeLists.txt
autotests/libinput/device_test.cpp
autotests/libinput/mock_libinput.cpp
autotests/libinput/mock_libinput.h
autotests/libinput/switch_event_test.cpp
config-kwin.h.cmake
libinput/connection.cpp
libinput/connection.h
libinput/device.cpp
libinput/device.h
libinput/events.cpp
libinput/events.h
To: graesslin, #kwin, #plasma
Cc: plasma-devel, kwin, ZrenBot, progwolff, lesliezhai, ali-mohamed, jensreuterberg, \
abetts, sebas, apol, mart
[Attachment #3 (unknown)]
<table><tr><td style="">graesslin created this revision.<br />graesslin added \
reviewers: KWin, Plasma.<br />Restricted Application added a project: KWin.<br \
/>Restricted Application added subscribers: kwin, plasma-devel.<br />Restricted \
Application edited projects, added Plasma; removed KWin. </td><a \
style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; \
color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; \
background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; \
border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D9516" \
rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION \
SUMMARY</strong><div><p>This change adds support for the switch devices introduces \
with libinput<br /> 1.7 (lid) and 1.9 (tablet mode). So far it's not yet used \
internally in<br /> KWin, but only exposed through the Device and Events.</p>
<p>As KWin currently only requires libinput 1.5 and we are rather late in<br />
the release cycle the new functionality is ifdef'ed. The requirement<br />
will be raised once master is 5.13. It is already available on<br />
build.kde.org, but e.g. Neon only has 1.6.</p>
<p>The switch events are interesting as they report whether the lid is<br />
closed (might be interesting for e.g. powerdevil) and whether a<br />
convertible is in tablet mode (supported for e.g. Lenovo Yogas with<br />
recent kernel). This can be used by KWin internally to enable/disable<br />
the virtual keyboard. And can be exposed globally to switch to Plasma<br />
Mobile shell in future.</p></div></div><br /><div><strong>TEST \
PLAN</strong><div><p>Only through test case as my Lenovo Yoga uses Neon which has \
a<br /> too old libinput</p></div></div><br \
/><div><strong>REPOSITORY</strong><div><div>R108 KWin</div></div></div><br \
/><div><strong>BRANCH</strong><div><div>libinput-switch</div></div></div><br \
/><div><strong>REVISION DETAIL</strong><div><a \
href="https://phabricator.kde.org/D9516" \
rel="noreferrer">https://phabricator.kde.org/D9516</a></div></div><br \
/><div><strong>AFFECTED FILES</strong><div><div>CMakeLists.txt<br /> \
autotests/libinput/CMakeLists.txt<br /> autotests/libinput/device_test.cpp<br />
autotests/libinput/mock_libinput.cpp<br />
autotests/libinput/mock_libinput.h<br />
autotests/libinput/switch_event_test.cpp<br />
config-kwin.h.cmake<br />
libinput/connection.cpp<br />
libinput/connection.h<br />
libinput/device.cpp<br />
libinput/device.h<br />
libinput/events.cpp<br />
libinput/events.h</div></div></div><br /><div><strong>To: </strong>graesslin, KWin, \
Plasma<br /><strong>Cc: </strong>plasma-devel, kwin, ZrenBot, progwolff, lesliezhai, \
ali-mohamed, jensreuterberg, abetts, sebas, apol, mart<br /></div>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic