summaryrefslogtreecommitdiffhomepage
path: root/opentrack-logic/work.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-06-29 10:37:15 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-06-29 13:18:30 +0200
commit3657d2c0d9807d6f88378981513a944cce4a1a16 (patch)
tree37f395ff7ace066ac6cdfaaba08bd200741fff14 /opentrack-logic/work.hpp
parentee7dbf946a77450e8bf49ea4b64e9b922a951c1f (diff)
logic, gui: no need to reference "struct main_settings"
Now that "struct main_settings" doesn't implicitly reload in dtor, we no longer have to pass it around from the user interface. Only reload it where it's modified, i.e. in the options dialog. Changing the filter/dialog/mapping comboboxen implicitly saves the main options however.
Diffstat (limited to 'opentrack-logic/work.hpp')
-rw-r--r--opentrack-logic/work.hpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/opentrack-logic/work.hpp b/opentrack-logic/work.hpp
index 2377be5a..37bc58bf 100644
--- a/opentrack-logic/work.hpp
+++ b/opentrack-logic/work.hpp
@@ -22,7 +22,7 @@
struct Work
{
- main_settings& s;
+ main_settings s;
SelectedLibraries& libs;
mem<Tracker> tracker;
mem<Shortcuts> sc;
@@ -31,9 +31,9 @@ struct Work
using tt = std::tuple<key_opts&, fn, bool>;
std::vector<tt> keys;
- Work(main_settings& s, Mappings& m, SelectedLibraries& libs, WId handle) :
- s(s), libs(libs),
- tracker(std::make_shared<Tracker>(s, m, libs)),
+ Work(Mappings& m, SelectedLibraries& libs, WId handle) :
+ libs(libs),
+ tracker(std::make_shared<Tracker>(m, libs)),
sc(std::make_shared<Shortcuts>()),
handle(handle),
keys {