Fix wayland activation
Adds support for xdg_activation_v1 when calling the application from the system tray by using KStatusNotifier which supports it. Listens to XDG_ACTIVATION_TOKEN as it's passed when we are started from dbus.
This commit is contained in:
committed by
Aleix Pol Gonzalez
parent
5c86692fb5
commit
265fcbfead
@@ -12,6 +12,7 @@
|
||||
#include <KWindowConfig>
|
||||
#ifdef HAVE_WINDOWSYSTEM
|
||||
#include <KWindowEffects>
|
||||
#include <KWindowSystem>
|
||||
#endif
|
||||
|
||||
#include <QAuthenticator>
|
||||
@@ -55,8 +56,10 @@
|
||||
#include "utils.h"
|
||||
#include <KStandardShortcut>
|
||||
|
||||
#ifndef Q_OS_ANDROID
|
||||
#if defined(Q_OS_WIN) || defined(Q_OS_MAC)
|
||||
#include "trayicon.h"
|
||||
#elif !defined(Q_OS_ANDROID)
|
||||
#include "trayicon_sni.h"
|
||||
#endif
|
||||
|
||||
using namespace Quotient;
|
||||
@@ -634,6 +637,13 @@ void Controller::setBlur(QQuickItem *item, bool blur)
|
||||
#endif
|
||||
}
|
||||
|
||||
void Controller::raiseWindow(QWindow *window)
|
||||
{
|
||||
#ifdef HAVE_WINDOWSYSTEM
|
||||
KWindowSystem::activateWindow(window->winId());
|
||||
#endif
|
||||
}
|
||||
|
||||
bool Controller::hasWindowSystem() const
|
||||
{
|
||||
#ifdef HAVE_WINDOWSYSTEM
|
||||
|
||||
Reference in New Issue
Block a user