9 Commits
Author SHA1 Message Date
Skycoder42 a0678c4cfc qpm update 2017-05-14 22:28:10 +02:00
Skycoder42 cdb4d37453 replaced XSync by XFlush 2017-05-14 22:27:26 +02:00
Skycoder42 9eace8fbbd do not discard events on XSync 2017-05-14 13:39:54 +02:00
Skycoder42 6baf644b40 fixed misread parameter
#3
2017-05-14 13:35:13 +02:00
Skycoder42 3fa176a380 Added XSync call for hotkey without window
For #3
2017-05-14 13:32:06 +02:00
Skycoder42 7c4ef6a03a qpm update 2017-05-01 12:17:18 +02:00
Skycoder42 15e34a7dbf fixed initial tab 2017-05-01 12:15:01 +02:00
Felix Barz b8f32c3381 Merge pull request #2 from ArsenArsen/patch-1
Fix a compile error on MXE
2017-05-01 12:13:48 +02:00
ArsenArsen 10d1e44b21 Fix a compile error on MXE 2017-05-01 11:48:53 +02:00
5 changed files with 14 additions and 3 deletions
+1 -1
View File
@@ -17,7 +17,7 @@
<item> <item>
<widget class="QTabWidget" name="tabWidget"> <widget class="QTabWidget" name="tabWidget">
<property name="currentIndex"> <property name="currentIndex">
<number>3</number> <number>0</number>
</property> </property>
<widget class="QWidget" name="playTab"> <widget class="QWidget" name="playTab">
<attribute name="title"> <attribute name="title">
+9
View File
@@ -1,11 +1,20 @@
#include "hottestwidget.h" #include "hottestwidget.h"
#include <QApplication> #include <QApplication>
//#define START_BACKGROUND
int main(int argc, char *argv[]) int main(int argc, char *argv[])
{ {
QApplication a(argc, argv); QApplication a(argc, argv);
HotTestWidget w; HotTestWidget w;
#ifdef START_BACKGROUND
auto startKey = new QHotkey(QKeySequence(Qt::MetaModifier | Qt::ControlModifier | Qt::Key_S), true, &w);
QObject::connect(startKey, &QHotkey::activated,
&w, &QWidget::show);
#else
w.show(); w.show();
#endif
return a.exec(); return a.exec();
} }
+2
View File
@@ -106,6 +106,7 @@ bool QHotkeyPrivateX11::registerShortcut(QHotkey::NativeShortcut shortcut)
GrabModeAsync, GrabModeAsync,
GrabModeAsync); GrabModeAsync);
} }
XFlush(display);
if(errorHandler.hasError) { if(errorHandler.hasError) {
qCWarning(logQHotkey) << "Failed to register hotkey. Error:" qCWarning(logQHotkey) << "Failed to register hotkey. Error:"
@@ -129,6 +130,7 @@ bool QHotkeyPrivateX11::unregisterShortcut(QHotkey::NativeShortcut shortcut)
shortcut.modifier | specialMod, shortcut.modifier | specialMod,
DefaultRootWindow(display)); DefaultRootWindow(display));
} }
XFlush(display);
if(errorHandler.hasError) { if(errorHandler.hasError) {
qCWarning(logQHotkey) << "Failed to unregister hotkey. Error:" qCWarning(logQHotkey) << "Failed to unregister hotkey. Error:"
+1 -1
View File
@@ -10,7 +10,7 @@ mac {
LIBS += -framework Carbon LIBS += -framework Carbon
} else:win32 { } else:win32 {
SOURCES += $$PWD/QHotkey/qhotkey_win.cpp SOURCES += $$PWD/QHotkey/qhotkey_win.cpp
LIBS += -lUser32 LIBS += -luser32
} else:unix { } else:unix {
SOURCES += $$PWD/QHotkey/qhotkey_x11.cpp SOURCES += $$PWD/QHotkey/qhotkey_x11.cpp
QT += x11extras QT += x11extras
+1 -1
View File
@@ -10,7 +10,7 @@
"url": "https://github.com/Skycoder42/QHotkey.git" "url": "https://github.com/Skycoder42/QHotkey.git"
}, },
"version": { "version": {
"label": "1.1.1", "label": "1.1.3",
"revision": "", "revision": "",
"fingerprint": "" "fingerprint": ""
}, },