WORKAROUND bug #335926

QXcbScreen overrides the input eventmask when
adding a screen, so we claim our stuff back

BUG: 335926
REVIEW: 118765
icc-effect-5.14.5
Thomas Lübking 2014-06-15 14:07:44 +02:00
parent c455087248
commit c654dd4ff1
2 changed files with 7 additions and 2 deletions

View File

@ -189,6 +189,12 @@ Workspace::Workspace(bool restore)
// Select windowmanager privileges
selectWmInputEventMask();
#if QT_VERSION < 0x050302
// WORKAROUND: QXcbScreen before 5.3.2 overrides them, see bug #335926, QTBUG-39648
// TODO once we depend on Qt 5.4 remove it
connect(qApp, SIGNAL(screenAdded(QScreen*)), this, SLOT(selectWmInputEventMask()));
#endif
#ifdef KWIN_BUILD_SCREENEDGES
ScreenEdges::create(this);
#endif
@ -1111,7 +1117,6 @@ void Workspace::selectWmInputEventMask()
{
uint32_t presentMask = 0;
Xcb::WindowAttributes attr(rootWindow());
Xcb::WindowGeometry geo(rootWindow());
if (!attr.isNull()) {
presentMask = attr->your_event_mask;
}

View File

@ -409,6 +409,7 @@ public Q_SLOTS:
private Q_SLOTS:
void desktopResized();
void selectWmInputEventMask();
void slotUpdateToolWindows();
void delayFocus();
void slotReloadConfig();
@ -451,7 +452,6 @@ private:
template <typename Slot>
void initShortcut(const QString &actionName, const QString &description, const QKeySequence &shortcut,
Slot slot, const QVariant &data = QVariant());
void selectWmInputEventMask();
void setupWindowShortcut(Client* c);
enum Direction {
DirectionNorth,