diff options
author | David Robillard <d@drobilla.net> | 2014-01-03 01:08:49 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2014-01-03 01:08:49 +0000 |
commit | 1e31d841f3513c39a7ac5b2d07cd18da7db92eed (patch) | |
tree | 14004ad393a9ea9ff2ba2aa8fcf1a046cd187383 /src/gui | |
parent | 250974e44a9cfb3cd33b2d902bc0daaaff1d6a14 (diff) | |
download | ingen-1e31d841f3513c39a7ac5b2d07cd18da7db92eed.tar.gz ingen-1e31d841f3513c39a7ac5b2d07cd18da7db92eed.tar.bz2 ingen-1e31d841f3513c39a7ac5b2d07cd18da7db92eed.zip |
Make graph input ports controllable outputs and remove double port kludge.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5247 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/GraphPortModule.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/gui/GraphPortModule.cpp b/src/gui/GraphPortModule.cpp index bc38bd55..7cca3869 100644 --- a/src/gui/GraphPortModule.cpp +++ b/src/gui/GraphPortModule.cpp @@ -46,13 +46,14 @@ GraphPortModule::GraphPortModule(GraphCanvas& canvas, SPtr<const Client::PortModel> model) : Ganv::Module(canvas, "", 0, 0, false) // FIXME: coords? , _model(model) + , _port(NULL) { assert(model); assert(dynamic_ptr_cast<const GraphModel>(model->parent())); set_stacked(model->polyphonic()); - if (model->is_input()) { + if (model->is_input() && !model->is_numeric()) { set_is_source(true); } @@ -71,13 +72,10 @@ GraphPortModule::create(GraphCanvas& canvas, GraphPortModule* ret = new GraphPortModule(canvas, model); Port* port = Port::create(canvas.app(), *ret, model, human, true); - if (model->is_numeric() && model->is_input()) { - // Add non-mirrored input so control port can be controlled from canvas - Port* p = Port::create(canvas.app(), *ret, model, human, false); - p->set_can_head(false); - } - ret->set_port(port); + if (model->is_numeric()) { + port->show_control(); + } for (const auto& p : model->properties()) ret->property_changed(p.first, p.second); |