summaryrefslogtreecommitdiffhomepage
path: root/logic/work.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2018-10-12 18:56:26 +0200
committerStanislaw Halik <sthalik@misaki.pl>2018-10-12 17:08:59 +0000
commitc57b524d3038dd1d94379038d362dea5b2896c60 (patch)
treee6946995a856f91d6e0f069fa8aa0a88e38d164d /logic/work.cpp
parent95d18c6a04b83943b0c3d095fedb681a2a0a2c0b (diff)
logic/pipeline: cleanup only
Diffstat (limited to 'logic/work.cpp')
-rw-r--r--logic/work.cpp24
1 files changed, 1 insertions, 23 deletions
diff --git a/logic/work.cpp b/logic/work.cpp
index c70864ae..da61b348 100644
--- a/logic/work.cpp
+++ b/logic/work.cpp
@@ -64,29 +64,7 @@ std::unique_ptr<TrackLogger> Work::make_logger(main_settings &s)
Work::Work(Mappings& m, event_handler& ev, QFrame* frame,
const dylibptr& tracker_, const dylibptr& filter_, const dylibptr& proto_) :
libs(frame, tracker_, filter_, proto_),
- logger{make_logger(s)},
- pipeline_{ m, libs, ev, *logger },
- keys {
-#if defined OTR_HAS_KEY_UP_SUPPORT
- key_tuple(s.key_center1, [&](bool x) { pipeline_.set_center(); pipeline_.set_held_center(x); }, false),
- key_tuple(s.key_center2, [&](bool x) { pipeline_.set_center(); pipeline_.set_held_center(x); }, false),
-#else
- key_tuple(s.key_center1, [&](bool) { pipeline_.set_center(); }, true),
- key_tuple(s.key_center2, [&](bool) { pipeline_.set_center(); }, true),
-#endif
-
- key_tuple(s.key_toggle1, [&](bool) { pipeline_.toggle_enabled(); }, true),
- key_tuple(s.key_toggle2, [&](bool) { pipeline_.toggle_enabled(); }, true),
-
- key_tuple(s.key_zero1, [&](bool) { pipeline_.toggle_zero(); }, true),
- key_tuple(s.key_zero2, [&](bool) { pipeline_.toggle_zero(); }, true),
-
- key_tuple(s.key_toggle_press1, [&](bool x) { pipeline_.set_enabled(!x); }, false),
- key_tuple(s.key_toggle_press2, [&](bool x) { pipeline_.set_enabled(!x); }, false),
-
- key_tuple(s.key_zero_press1, [&](bool x) { pipeline_.set_zero(x); }, false),
- key_tuple(s.key_zero_press2, [&](bool x) { pipeline_.set_zero(x); }, false),
- }
+ pipeline_{ m, libs, ev, *logger }
{
if (!is_ok())
return;