<table><tr><td style="">wbauer created this revision.<br />Restricted Application added a project: Plasma.<br />Restricted Application added a subscriber: plasma-devel.
</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/D6048" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>Because of C++'s operator precedence, '!' logically negated all_event_masks only instead of the whole expression.<br />
This resulted in the condition always being false and XTest never being used.</p>
<p>Adding a pair of brackets fixes it.</p>
<p>BUG: 362941<br />
BUG: 375017</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>Verifed with debug output that XTest is being used when XCB_EVENT_MASK_BUTTON_PRESS is not set in all_event_masks.</p>
<p>Tested with a couple of applications:</p>
<ul class="remarkup-list">
<li class="remarkup-list-item">mplayerc.exe: wine app, worked before, no XTest, still works</li>
<li class="remarkup-list-item">tvbrowser, jedit, jitsi 2.8: java apps, didn't work before, use XTest now and work</li>
<li class="remarkup-list-item">ksensors, ksteak, kconnections, klinpopup, ktvschedule: KDE3 apps, worked before, no XTest, still work</li>
<li class="remarkup-list-item">wammu: python/wxWidgets app, worked before, no XTest, still works</li>
<li class="remarkup-list-item">grip, avidemux2, hexchat: gtk2 apps, worked before, no XTest, still work</li>
<li class="remarkup-list-item">audacious, stardict: gtk3 apps, didn't work before (unless GDK_CORE_DEVICE_EVENTS=1 was set), work now using XTest (without GDK_CORE_DEVICE_EVENTS=1)</li>
</ul></div></div><br /><div><strong>REPOSITORY</strong><div><div>R120 Plasma Workspace</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D6048" rel="noreferrer">https://phabricator.kde.org/D6048</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>xembed-sni-proxy/sniproxy.cpp</div></div></div><br /><div><strong>To: </strong>wbauer, Plasma, davidedmundson<br /><strong>Cc: </strong>plasma-devel, ZrenBot, spstarr, progwolff, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart, lukas<br /></div>