diff options
author | David Robillard <d@drobilla.net> | 2017-12-25 15:26:48 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2017-12-25 16:26:13 -0500 |
commit | 15b3b0e9f8823752f80c7e597a70749813e61c79 (patch) | |
tree | 3f324c6e2a455be8b929456dadbf06520889d435 /src/client/ClientStore.cpp | |
parent | d6a9571641bcb34acb3521feb08eea33195fd9ca (diff) | |
download | ingen-15b3b0e9f8823752f80c7e597a70749813e61c79.tar.gz ingen-15b3b0e9f8823752f80c7e597a70749813e61c79.tar.bz2 ingen-15b3b0e9f8823752f80c7e597a70749813e61c79.zip |
Always use braces
Diffstat (limited to 'src/client/ClientStore.cpp')
-rw-r--r-- | src/client/ClientStore.cpp | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/client/ClientStore.cpp b/src/client/ClientStore.cpp index c5749388..e91277d9 100644 --- a/src/client/ClientStore.cpp +++ b/src/client/ClientStore.cpp @@ -80,8 +80,9 @@ ClientStore::add_object(SPtr<ObjectModel> object) } } - for (auto p : object->properties()) + for (auto p : object->properties()) { object->signal_property().emit(p.first, p.second); + } } SPtr<ObjectModel> @@ -400,21 +401,26 @@ ClientStore::connection_graph(const Raul::Path& tail_path, { SPtr<GraphModel> graph; - if (tail_path.parent() == head_path.parent()) + if (tail_path.parent() == head_path.parent()) { graph = dynamic_ptr_cast<GraphModel>(_object(tail_path.parent())); + } - if (!graph && tail_path.parent() == head_path.parent().parent()) + if (!graph && tail_path.parent() == head_path.parent().parent()) { graph = dynamic_ptr_cast<GraphModel>(_object(tail_path.parent())); + } - if (!graph && tail_path.parent().parent() == head_path.parent()) + if (!graph && tail_path.parent().parent() == head_path.parent()) { graph = dynamic_ptr_cast<GraphModel>(_object(head_path.parent())); + } - if (!graph) + if (!graph) { graph = dynamic_ptr_cast<GraphModel>(_object(tail_path.parent().parent())); + } - if (!graph) + if (!graph) { _log.error(fmt("Unable to find graph for arc %1% => %2%\n") % tail_path % head_path); + } return graph; } @@ -450,8 +456,9 @@ ClientStore::operator()(const Disconnect& msg) SPtr<PortModel> tail = dynamic_ptr_cast<PortModel>(_object(msg.tail)); SPtr<PortModel> head = dynamic_ptr_cast<PortModel>(_object(msg.head)); SPtr<GraphModel> graph = connection_graph(msg.tail, msg.head); - if (graph) + if (graph) { graph->remove_arc(tail.get(), head.get()); + } } void |