diff options
Diffstat (limited to 'src/plugins/General/hotkey/hotkeymanager_x11.cpp')
| -rw-r--r-- | src/plugins/General/hotkey/hotkeymanager_x11.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/plugins/General/hotkey/hotkeymanager_x11.cpp b/src/plugins/General/hotkey/hotkeymanager_x11.cpp index 016f132ba..26aac352b 100644 --- a/src/plugins/General/hotkey/hotkeymanager_x11.cpp +++ b/src/plugins/General/hotkey/hotkeymanager_x11.cpp @@ -78,6 +78,12 @@ quint32 Hotkey::defaultKey(int act) HotkeyManager::HotkeyManager(QObject *parent) : QObject(parent) { + if(!QX11Info::isPlatformX11()) + { + qWarning("HotkeyManager: X11 not found. Plugin disabled"); + return; + } + QCoreApplication::instance()->installEventFilter(this); WId rootWindow = DefaultRootWindow(QX11Info::display()); QSettings settings(Qmmp::configFile(), QSettings::IniFormat); //load settings |
