diff options
author | David Robillard <d@drobilla.net> | 2020-11-28 23:20:45 +0100 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2020-11-28 23:20:45 +0100 |
commit | 228815993b4ecc31a345628fd85e6b75e564ecfe (patch) | |
tree | 06515a5e069dbfee55683767046a288f73719c43 /src/PatchageModule.cpp | |
parent | f95ca1978dd463d1e6c640bb00d4d420ccb9d593 (diff) | |
download | patchage-228815993b4ecc31a345628fd85e6b75e564ecfe.tar.gz patchage-228815993b4ecc31a345628fd85e6b75e564ecfe.tar.bz2 patchage-228815993b4ecc31a345628fd85e6b75e564ecfe.zip |
Reduce use of raw new and delete
Diffstat (limited to 'src/PatchageModule.cpp')
-rw-r--r-- | src/PatchageModule.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/PatchageModule.cpp b/src/PatchageModule.cpp index 9b56856..a4d2fe9 100644 --- a/src/PatchageModule.cpp +++ b/src/PatchageModule.cpp @@ -110,7 +110,7 @@ PatchageModule::load_location() { Coord loc; - if (_app->conf()->get_module_location(_name, _type, loc)) { + if (_app->conf().get_module_location(_name, _type, loc)) { move_to(loc.x, loc.y); } else { move_to(20 + rand() % 640, 20 + rand() % 480); @@ -120,14 +120,14 @@ PatchageModule::load_location() void PatchageModule::store_location(double x, double y) { - _app->conf()->set_module_location(_name, _type, {x, y}); + _app->conf().set_module_location(_name, _type, {x, y}); } void PatchageModule::split() { assert(_type == SignalDirection::duplex); - _app->conf()->set_module_split(_name, true); + _app->conf().set_module_split(_name, true); _app->refresh(); } @@ -135,7 +135,7 @@ void PatchageModule::join() { assert(_type != SignalDirection::duplex); - _app->conf()->set_module_split(_name, false); + _app->conf().set_module_split(_name, false); _app->refresh(); } |