summaryrefslogtreecommitdiffhomepage
path: root/opentrack-logic/shortcuts.h
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-06-29 13:02:41 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-06-29 13:18:31 +0200
commit2dd8064c20d88c26a11240c6a871f670b5109d71 (patch)
treea6aa04113adc5837f02548464766b9291ecab89a /opentrack-logic/shortcuts.h
parent2eccd41897d6794a80b3ed2fcaaded85c453d46d (diff)
logic, gui: reload keybinding description on profile change
Diffstat (limited to 'opentrack-logic/shortcuts.h')
-rw-r--r--opentrack-logic/shortcuts.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/opentrack-logic/shortcuts.h b/opentrack-logic/shortcuts.h
index 87e24d4f..d6a87672 100644
--- a/opentrack-logic/shortcuts.h
+++ b/opentrack-logic/shortcuts.h
@@ -45,6 +45,8 @@ public:
using fun = std::function<void(bool)>;
using tt = std::tuple<K, fun, bool>;
+ using t_key = std::tuple<key_opts&, fun, bool>;
+ using t_keys = std::vector<t_key>;
std::vector<tt> keys;
#ifdef _WIN32
KeybindingWorker::Token key_token;
@@ -56,10 +58,10 @@ public:
#endif
{}
- void reload(const std::vector<std::tuple<key_opts&, fun, bool>> &keys_);
+ void reload(const t_keys& keys_);
private:
void free_binding(K& key);
- void bind_keyboard_shortcut(K &key, const key_opts& k, bool held);
+ void bind_shortcut(K &key, const key_opts& k, bool held);
#ifdef _WIN32
void receiver(const Key& k);
#endif