summaryrefslogtreecommitdiffstats
path: root/src/libs/gui/NodeModule.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/gui/NodeModule.cpp')
-rw-r--r--src/libs/gui/NodeModule.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libs/gui/NodeModule.cpp b/src/libs/gui/NodeModule.cpp
index f8308264..97edaa84 100644
--- a/src/libs/gui/NodeModule.cpp
+++ b/src/libs/gui/NodeModule.cpp
@@ -230,9 +230,9 @@ NodeModule::add_port(SharedPtr<PortModel> port, bool resize_to_fit)
{
uint32_t index = _ports.size(); // FIXME: kludge, engine needs to tell us this
- string name = (App::instance().configuration()->name_style() == Configuration::PATH)
- ? port->path().name()
- : ((PluginModel*)node()->plugin())->port_human_name(index);
+ string name = port->path().name();
+ if (App::instance().configuration()->name_style() == Configuration::HUMAN && node()->plugin())
+ name = ((PluginModel*)node()->plugin())->port_human_name(index);
Module::add_port(boost::shared_ptr<Port>(
new Port(PtrCast<NodeModule>(shared_from_this()), port, name)));