diff options
author | David Robillard <d@drobilla.net> | 2009-05-10 00:21:37 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2009-05-10 00:21:37 +0000 |
commit | 9ea901df533b0326e715ced10b9e9970239da515 (patch) | |
tree | 811f2f23140e656673c1b237fd70486f1d8e2058 /src | |
parent | 7886e32dfac16fad93172b72932d89e8cf254e93 (diff) | |
download | ingen-9ea901df533b0326e715ced10b9e9970239da515.tar.gz ingen-9ea901df533b0326e715ced10b9e9970239da515.tar.bz2 ingen-9ea901df533b0326e715ced10b9e9970239da515.zip |
Show current value for all ports (not just plugin node ports) in status bar on hover.
Fix ticket #358.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@1970 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/PatchView.cpp | 4 | ||||
-rw-r--r-- | src/gui/PatchWindow.cpp | 19 |
2 files changed, 12 insertions, 11 deletions
diff --git a/src/gui/PatchView.cpp b/src/gui/PatchView.cpp index 31a89375..c441a64a 100644 --- a/src/gui/PatchView.cpp +++ b/src/gui/PatchView.cpp @@ -163,10 +163,8 @@ void PatchView::canvas_item_entered(Gnome::Canvas::Item* item) { NodeModule* m = dynamic_cast<NodeModule*>(item); - if (m) { + if (m) signal_object_entered.emit(m->node().get()); - return; - } Port* p = dynamic_cast<Port*>(item); if (p) diff --git a/src/gui/PatchWindow.cpp b/src/gui/PatchWindow.cpp index 377ff59f..14aab7d9 100644 --- a/src/gui/PatchWindow.cpp +++ b/src/gui/PatchWindow.cpp @@ -313,17 +313,20 @@ PatchWindow::object_entered(ObjectModel* model) NodeModel* parent = dynamic_cast<NodeModel*>(port->parent().get()); if (parent) { const PluginModel* plugin = dynamic_cast<const PluginModel*>(parent->plugin()); + if (plugin) { - msg.append((boost::format(" (%1%)") - % plugin->port_human_name(port->index())).str()); - const Atom& value = port->value(); - if (value.is_valid()) { - const Redland::Node node = AtomRDF::atom_to_node( - *App::instance().world()->rdf_world, value); - msg.append(" = ").append(node.to_string()); - } + const string human_name = plugin->port_human_name(port->index()); + if (human_name != "") + msg.append((boost::format(" (%1%)") % human_name).str()); } } + + const Atom& value = port->value(); + if (value.is_valid()) { + const Redland::Node node = AtomRDF::atom_to_node( + *App::instance().world()->rdf_world, value); + msg.append(" = ").append(node.to_string()); + } } _status_bar->push(msg, STATUS_CONTEXT_HOVER); |