summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2015-11-01 11:29:48 +0100
committerStanislaw Halik <sthalik@misaki.pl>2015-11-01 11:29:48 +0100
commit712f2e6c09713024d0d92f129577b498d5945fb7 (patch)
treecd4c7e73360e82c05a3f826f9cd5df12a0dd2401
parent014e021d36e1096f17d999f42e64e89d3ffd3f01 (diff)
shortcuts: cleanup
-rw-r--r--opentrack/shortcuts.h27
1 files changed, 15 insertions, 12 deletions
diff --git a/opentrack/shortcuts.h b/opentrack/shortcuts.h
index 03adc1ab..81c1bb80 100644
--- a/opentrack/shortcuts.h
+++ b/opentrack/shortcuts.h
@@ -30,18 +30,15 @@
using namespace options;
-extern QList<QString> global_key_sequences;
-
-struct key_opts {
- value<QString> keycode;
-
- key_opts(pbundle b, const QString& name) :
- keycode(b, QString("keycode-%1").arg(name), "")
- {}
-};
+namespace {
+ extern QList<QString> global_key_sequences;
+}
#if defined(_WIN32)
-extern QList<int> global_windows_key_sequences;
+
+namespace {
+ extern QList<int> global_windows_key_sequences;
+}
# undef DIRECTINPUT_VERSION
# define DIRECTINPUT_VERSION 0x0800
# include <windows.h>
@@ -111,6 +108,14 @@ public:
#ifdef _WIN32
mem<KeybindingWorker> keybindingWorker;
#endif
+
+ struct key_opts {
+ value<QString> keycode;
+
+ key_opts(pbundle b, const QString& name) :
+ keycode(b, QString("keycode-%1").arg(name), "")
+ {}
+ };
struct settings : opts {
key_opts center, toggle, zero;
@@ -136,5 +141,3 @@ signals:
void toggle();
void zero();
};
-
-