diff options
author | David Robillard <d@drobilla.net> | 2014-08-28 16:20:35 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2014-08-28 16:20:35 +0000 |
commit | b5195d8cf6a8ed5c446284f904e5704748915450 (patch) | |
tree | 311f27572a29e7a0c98df3616cf6d1a7c39400d2 /src | |
parent | 9bd6508264e2aef1c4afb1df585ee375016789ea (diff) | |
download | ingen-b5195d8cf6a8ed5c446284f904e5704748915450.tar.gz ingen-b5195d8cf6a8ed5c446284f904e5704748915450.tar.bz2 ingen-b5195d8cf6a8ed5c446284f904e5704748915450.zip |
Don't show value menu items for control outputs.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5453 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/PortMenu.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/gui/PortMenu.cpp b/src/gui/PortMenu.cpp index 7eeef5b1..70fb4f4e 100644 --- a/src/gui/PortMenu.cpp +++ b/src/gui/PortMenu.cpp @@ -65,6 +65,7 @@ PortMenu::init(App& app, SPtr<const PortModel> port, bool is_graph_port) const bool is_control(app.can_control(port.get()) && port->is_numeric()); const bool is_on_graph(dynamic_ptr_cast<GraphModel>(port->parent())); + const bool is_input(port->is_input()); if (!_is_graph_port) { _polyphonic_menuitem->set_sensitive(false); @@ -76,12 +77,12 @@ PortMenu::init(App& app, SPtr<const PortModel> port, bool is_graph_port) _polyphonic_menuitem->hide(); } - _reset_range_menuitem->set_visible(is_control && !is_on_graph); - _set_max_menuitem->set_visible(is_control); - _set_min_menuitem->set_visible(is_control); + _reset_range_menuitem->set_visible(is_input && is_control && !is_on_graph); + _set_max_menuitem->set_visible(is_input && is_control); + _set_min_menuitem->set_visible(is_input && is_control); _expose_menuitem->set_visible(!is_on_graph); - _learn_menuitem->set_visible(is_control); - _unlearn_menuitem->set_visible(is_control); + _learn_menuitem->set_visible(is_input && is_control); + _unlearn_menuitem->set_visible(is_input && is_control); if (!is_control && is_on_graph) { _separator_menuitem->hide(); |