diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2016-09-05 22:47:41 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2016-09-06 04:03:38 +0200 |
commit | fe5298dd106579e257c05fa6f0c8f63b10504a61 (patch) | |
tree | c0be67ccbfd3245937f79ab80fc5d340e13ede16 /logic/work.cpp | |
parent | aac3d4b4578585b8b3f96685502f2941d492ee1a (diff) |
gui, logic: add shortcut for "translation compensation off while held"
Requested-by: @Sone989
Issue: #440
Diffstat (limited to 'logic/work.cpp')
-rw-r--r-- | logic/work.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/logic/work.cpp b/logic/work.cpp index 8d00270b..c369921c 100644 --- a/logic/work.cpp +++ b/logic/work.cpp @@ -53,7 +53,8 @@ Work::Work(Mappings& m, SelectedLibraries& libs, WId handle) : key_tuple(s.key_zero, [&](bool) -> void { tracker->zero(); }, true), key_tuple(s.key_toggle_press, [&](bool x) -> void { tracker->set_toggle(!x); }, false), key_tuple(s.key_zero_press, [&](bool x) -> void { tracker->set_zero(x); }, false), - } + key_tuple(s.key_disable_tcomp_press, [&](bool x) { tracker->set_tcomp_disabled(x); }, false), + } { reload_shortcuts(); tracker->start(); @@ -66,8 +67,8 @@ void Work::reload_shortcuts() Work::~Work() { - sc = nullptr; // order matters, otherwise use-after-free -sh + sc = nullptr; tracker = nullptr; libs = SelectedLibraries(); } |