diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2015-11-22 18:05:04 +0100 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2015-11-22 18:05:04 +0100 |
commit | e2ea45a81d5f30fdbd42e0b03a192afa81e877dc (patch) | |
tree | fc5334a9ecf3fcba8671ea2e8330460fcc2c82c8 /opentrack/keybinding-worker.hpp | |
parent | 5d4a9c78fbbbd59d366e91bfe4c4263d12833abe (diff) |
api/shortcuts: don't provide guard/stubs for non-win32
The worker class is win32-only. Don't guard there, consumers are
expected only to include it on _WIN32.
For the same reason don't provide a stub for the keybinding worker.
Diffstat (limited to 'opentrack/keybinding-worker.hpp')
-rw-r--r-- | opentrack/keybinding-worker.hpp | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/opentrack/keybinding-worker.hpp b/opentrack/keybinding-worker.hpp index 83ffadf1..e3967682 100644 --- a/opentrack/keybinding-worker.hpp +++ b/opentrack/keybinding-worker.hpp @@ -15,20 +15,17 @@ #endif #include "opentrack-compat/timer.hpp" -#ifdef _WIN32 -# include "opentrack/win32-joystick.hpp" -#endif +#include "opentrack/win32-joystick.hpp" #include <QThread> #include <QMutex> #include <QWidget> #include <functional> #include <vector> -#ifdef _WIN32 -# undef DIRECTINPUT_VERSION -# define DIRECTINPUT_VERSION 0x0800 -# include <windows.h> -# include <dinput.h> +#undef DIRECTINPUT_VERSION +#define DIRECTINPUT_VERSION 0x0800 +#include <windows.h> +#include <dinput.h> struct Key { BYTE keycode; QString guid; @@ -51,15 +48,10 @@ public: return ret; } }; -#else -typedef unsigned char BYTE; -struct Key { int foo; }; -#endif struct OPENTRACK_EXPORT KeybindingWorker : private QThread { private: -#ifdef _WIN32 LPDIRECTINPUT8 din; LPDIRECTINPUTDEVICE8 dinkeyboard; win32_joy_ctx& joy_ctx; @@ -99,7 +91,5 @@ public: { return Token(receiver); } -#else void run() override {} -#endif }; |