Try to avoid coincident tempo/meter markers when removing time
[ardour.git] / gtk2_ardour / port_group.cc
index 213c818b0bae05b0a25a0f356479bd1af401e29d..448a8d3cf55840bb0a45728bf2d350cfb63253fa 100644 (file)
@@ -438,7 +438,7 @@ PortGroupList::gather (ARDOUR::Session* session, ARDOUR::DataType type, bool inp
                ardour->add_bundle (ltc);
        }
 
-       /* Ardour's surfaces */
+       /* Ardour's control surfaces */
 
        ControlProtocolManager& m = ControlProtocolManager::instance ();
        for (list<ControlProtocolInfo*>::iterator i = m.control_protocol_info.begin(); i != m.control_protocol_info.end(); ++i) {
@@ -610,7 +610,12 @@ PortGroupList::make_bundle_from_ports (std::vector<std::string> const & p, ARDOU
        }
 
        for (uint32_t j = 0; j < p.size(); ++j) {
-               b->add_channel (p[j].substr (pre.length()), type);
+               std::string n = p[j].substr (pre.length());
+               std::string pn = AudioEngine::instance()->get_pretty_name_by_name (p[j]);
+               if (!pn.empty()) {
+                       n = pn;
+               }
+               b->add_channel (n, type);
                b->set_port (j, p[j]);
        }