Remove ifdef(Q_OS_X11) code, there never was such a define.

As noone complained since I don't think anyone will miss the code
This commit is contained in:
Hannah von Reth 2020-06-25 16:25:11 +02:00 committed by Kevin Ottens
parent e4b7ed8fd6
commit 4645e69147
No known key found for this signature in database
GPG key ID: 074BBBCB8DECC9E2

View file

@ -42,9 +42,6 @@
#include <QtDBus/QDBusInterface>
#endif
#if defined(Q_OS_X11)
#include <QX11Info>
#endif
#include <QQmlEngine>
#include <QQmlComponent>
@ -592,30 +589,7 @@ void ownCloudGui::raiseDialog(QWidget *raiseWidget)
raiseWidget->showNormal();
raiseWidget->raise();
raiseWidget->activateWindow();
#if defined(Q_OS_X11)
WId wid = widget->winId();
NETWM::init();
XEvent e;
e.xclient.type = ClientMessage;
e.xclient.message_type = NETWM::NET_ACTIVE_WINDOW;
e.xclient.display = QX11Info::display();
e.xclient.window = wid;
e.xclient.format = 32;
e.xclient.data.l[0] = 2;
e.xclient.data.l[1] = QX11Info::appTime();
e.xclient.data.l[2] = 0;
e.xclient.data.l[3] = 0l;
e.xclient.data.l[4] = 0l;
Display *display = QX11Info::display();
XSendEvent(display,
RootWindow(display, DefaultScreen(display)),
False, // propagate
SubstructureRedirectMask | SubstructureNotifyMask,
&e);
#elif defined(Q_OS_WIN)
#ifdef Q_OS_WIN
// Windows disallows raising a Window when you're not the active application.
// Use a common hack to attach to the active application
const auto activeProcessId = GetWindowThreadProcessId(GetForegroundWindow(), nullptr);