<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="12" style="border: 1px #c9c399 solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://git.reviewboard.kde.org/r/126513/">https://git.reviewboard.kde.org/r/126513/</a>
</td>
</tr>
</table>
<br />
<table bgcolor="#e0e0e0" width="100%" cellpadding="12" style="border: 1px gray solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
<tr>
<td>
<h1 style="margin: 0; padding: 0; font-size: 10pt;">This change has been marked as submitted.</h1>
</td>
</tr>
</table>
<br />
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="12" style="border: 1px #888a85 solid; border-radius: 6px; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
<tr>
<td>
<div>Review request for Plasma and David Edmundson.</div>
<div>By Xuetian Weng.</div>
<p style="color: grey;"><i>Updated Jan. 11, 2016, 8:54 p.m.</i></p>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Changes</h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Submitted with commit a39677c1fd1e6303ddaf31da5ccd0a6454104066 by Weng Xuetian to branch master.</pre>
</td>
</tr>
</table>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>
<a href="https://bugs.kde.org/show_bug.cgi?id=349545">349545</a>,
<a href="https://bugs.kde.org/show_bug.cgi?id=356923">356923</a>
</div>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
plasma-desktop
</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">Currently, there are some mixed issue in kcm touchpad related to libinput backend and hot plug.
There are several issues:
1. only one backend maybe used at runtime, either synaptics or libinput. But libinput backend will only be used if there is a libinput backend present. Which means if libinput touchpad is not present at login, kded will not be able to properly support them.
2. hotplug touchpad will always set touchpad to disabled.
3. hotplug touchpad will not get configuration applied.
4. The libinput devices detection may pick some non-touchpad device. </p>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">To solve these problems, following changes are made:
1. Remove SynapticsBackend and LibinputBackend and add three new classes called XlibTouchpad/SynapticsTouchpad/LibinputTouchpad. So findTouchpad may pick up both synaptics or libinput device, and no need to depend on a fixed backend. This change also make it easier to support multiple touchpad device easier if needed.</p>
<ol style="padding: 0;text-rendering: inherit;margin: 0 0 0 2em;line-height: inherit;white-space: normal;">
<li style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: normal;">
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">hotplug touchpad config not being applied (bug 356923) is mainly because one can't apply settings to a disabled device. Change the statement order in handleReset, apply settings first then set enable status.</p>
</li>
<li style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: normal;">
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">findTouchpad() is changed to use XListInputDevices, because it provides necessary information of device type in order to filter out non-touchpad device. xf86-input-libinput doesn't have a unique atom for touchpad, so current identityAtom cannot guarantee that findTouchpad always returns a touchpad device for libinput.</p>
</li>
<li style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: normal;">
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">On my surface pro 4 system, if touchpad is unpluged, the device will be set to disabled automatically first, then touchpadDetached is called, which makes m_enabled in TouchpadDisabled always to be false after unplug the touchapd. This patch makes TouchpadDisabler have two different enabled property. m_userRequestedState only stores the user requested status, so when handleReset is called, it can properly set enabled state to the last user requested state.</p>
</li>
</ol></pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;"><p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">Without touchpad -> login -> plug touchpad -> settings applied to device using libinput driver.
unplug -> replug -> settings applied to device using libinput driver.</p>
<p style="padding: 0;text-rendering: inherit;margin: 0;line-height: inherit;white-space: inherit;">Disable touchpad -> applet shows up -> unplug touchpad -> applet hides -> replug touchpad -> touchpad is still disabled, and applet shows up -> enable touhcpad -> applet hides.</p></pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>kcms/touchpad/src/applet/qml/contents/ui/touchpad.qml <span style="color: grey">(8dec7c2)</span></li>
<li>kcms/touchpad/src/applet/touchpadengine.h <span style="color: grey">(16b98c2)</span></li>
<li>kcms/touchpad/src/applet/touchpadengine.cpp <span style="color: grey">(eae429e)</span></li>
<li>kcms/touchpad/src/backends/x11.cmake <span style="color: grey">(c9fcea8)</span></li>
<li>kcms/touchpad/src/backends/x11/libinputproperties.c <span style="color: grey">(9dbf9ea)</span></li>
<li>kcms/touchpad/src/backends/x11/libinputtouchpad.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/libinputtouchpad.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/propertyinfo.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/propertyinfo.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/synapticstouchpad.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/synapticstouchpad.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/synclientproperties.h <span style="color: grey">(43d18d2)</span></li>
<li>kcms/touchpad/src/backends/x11/synclientproperties.c <span style="color: grey">(5fd1ed6)</span></li>
<li>kcms/touchpad/src/backends/x11/xlibbackend.h <span style="color: grey">(7cecb4a)</span></li>
<li>kcms/touchpad/src/backends/x11/xlibbackend.cpp <span style="color: grey">(b55a45f)</span></li>
<li>kcms/touchpad/src/backends/x11/xlibtouchpad.h <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/backends/x11/xlibtouchpad.cpp <span style="color: grey">(PRE-CREATION)</span></li>
<li>kcms/touchpad/src/kded/kded.h <span style="color: grey">(9b8fe6e)</span></li>
<li>kcms/touchpad/src/kded/kded.cpp <span style="color: grey">(409126b)</span></li>
<li>kcms/touchpad/src/touchpadbackend.h <span style="color: grey">(b225ed9)</span></li>
</ul>
<p><a href="https://git.reviewboard.kde.org/r/126513/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>