Make foldback bus match foldback sends namewise
authorLen Ovens <len@ovenwerks.net>
Tue, 13 Nov 2018 06:29:27 +0000 (22:29 -0800)
committerLen Ovens <len@ovenwerks.net>
Tue, 13 Nov 2018 06:30:32 +0000 (22:30 -0800)
to avoid confusion with listener sends or monitor bus

gtk2_ardour/add_route_dialog.cc
gtk2_ardour/add_route_dialog.h
gtk2_ardour/ardour_ui.cc
gtk2_ardour/ardour_ui.h
gtk2_ardour/processor_box.cc
libs/ardour/ardour/presentation_info.h
libs/ardour/ardour/stripable.h
libs/ardour/enums.cc
libs/ardour/presentation_info.cc
libs/ardour/session.cc
libs/surfaces/osc/osc.cc

index 57c9cc2719a4b00c0a2e72f24d5c51a024192d92..d3632114020f88d7211d656ae931c2a87084061e 100644 (file)
@@ -172,14 +172,14 @@ You may select:\n \
 ")
                ));
                builtin_types.push_back (
-                       std::pair<string,string>(_("Listen Busses"),   _(" \
-Use the settings, below, to create new Listen Busses.\n \
-Listen Busses are used as master outputs for monitor channels which are fed by\n \
+                       std::pair<string,string>(_("Foldback Busses"),   _(" \
+Use the settings, below, to create new Foldback Busses.\n \
+Foldback Busses are used as master outputs for monitor channels which are fed by\n \
 hidden monitor sends.\n \
 \n\n \
 You may select:\n \
-* The number of Listen Busses to add.\n \
-* A name for the new Listen Busses.\n \
+* The number of Foldback Busses to add.\n \
+* A name for the new Foldback Busses.\n \
 ")
                ));
        }
@@ -580,8 +580,8 @@ AddRouteDialog::type_wanted()
                return AudioTrack;
        } else if (str == _("VCA Masters")) {
                return VCAMaster;
-       } else if (str == _("Listen Busses")) {
-               return ListenBus;
+       } else if (str == _("Foldback Busses")) {
+               return FoldbackBus;
        } else {
                assert (0);
                return AudioTrack;
@@ -609,8 +609,8 @@ AddRouteDialog::maybe_update_name_template_entry ()
        case MidiBus:
                name_template_entry.set_text (_("Bus"));
                break;
-       case ListenBus:
-               name_template_entry.set_text (_("Listener"));
+       case FoldbackBus:
+               name_template_entry.set_text (_("Foldback"));
                break;
        case VCAMaster:
                name_template_entry.set_text (VCA::default_name_template());
@@ -757,7 +757,7 @@ AddRouteDialog::track_type_chosen ()
                insert_at_combo.set_sensitive (true);
 
                break;
-       case ListenBus:
+       case FoldbackBus:
 
                configuration_label.set_sensitive (false);
                channel_combo.set_sensitive (false);
@@ -878,7 +878,7 @@ AddRouteDialog::channels ()
                ret.set (DataType::MIDI, 1);
                break;
 
-       case ListenBus:
+       case FoldbackBus:
                ret.set (DataType::AUDIO, 2);
                ret.set (DataType::MIDI, 0);
                break;
index 381bebee4457bdfb7fd6967ae12cef4a8a3a9d1b..ec058dc1307cc5a463437a808bdc0ba642d1e851 100644 (file)
@@ -67,7 +67,7 @@ public:
                AudioBus,
                MidiBus,
                VCAMaster,
-               ListenBus,
+               FoldbackBus,
        };
        TypeWanted type_wanted();
 
index 049d26b0699ada27b6c5c0bfe1aae4aa4d612534..0523f9a8d11f9843c3800d8fbfc24b813cd52d31 100644 (file)
@@ -2123,17 +2123,17 @@ ARDOUR_UI::session_add_audio_route (
 }
 
 void
-ARDOUR_UI::session_add_listen_bus (uint32_t how_many, string const & name_template)
+ARDOUR_UI::session_add_foldback_bus (uint32_t how_many, string const & name_template)
 {
        RouteList routes;
 
        assert (_session);
 
        try {
-               routes = _session->new_audio_route (2, 2, 0, how_many, name_template, PresentationInfo::ListenBus, -1);
+               routes = _session->new_audio_route (2, 2, 0, how_many, name_template, PresentationInfo::FoldbackBus, -1);
 
                if (routes.size() != how_many) {
-                       error << string_compose (P_("could not create %1 new listen bus", "could not create %1 new listen busses", how_many), how_many)
+                       error << string_compose (P_("could not create %1 new foldback bus", "could not create %1 new foldback busses", how_many), how_many)
                              << endmsg;
                }
        }
@@ -4427,8 +4427,8 @@ ARDOUR_UI::add_route_dialog_response (int r)
        case AddRouteDialog::VCAMaster:
                _session->vca_manager().create_vca (count, name_template);
                break;
-       case AddRouteDialog::ListenBus:
-               session_add_listen_bus (count, name_template);
+       case AddRouteDialog::FoldbackBus:
+               session_add_foldback_bus (count, name_template);
                break;
        }
 }
index 1f0e1145e98e3bf99f089ce45efe69695e78a9b5..d570dc79bb2d3abef156da56e60b4b78aa226a93 100644 (file)
@@ -316,7 +316,7 @@ public:
                                     ARDOUR::PluginInfoPtr, ARDOUR::Plugin::PresetRecord*,
                                     ARDOUR::PresentationInfo::order_t order);
 
-       void session_add_listen_bus (uint32_t, std::string const &);
+       void session_add_foldback_bus (uint32_t, std::string const &);
 
        void display_insufficient_ports_message ();
 
index 21937bc6074acb86e3098fa4e01c4e3e1bb618c0..550bdc28263801a3ea3a7dca57008e28da04917c 100644 (file)
@@ -2034,7 +2034,7 @@ ProcessorBox::build_possible_aux_menu ()
                return 0;
        }
 
-       if (_route->is_monitor () || _route->is_listenbus ()) {
+       if (_route->is_monitor () || _route->is_foldbackbus ()) {
                return 0;
        }
 
@@ -2047,7 +2047,7 @@ ProcessorBox::build_possible_aux_menu ()
                        /* don't allow sending to master or monitor or to self */
                        continue;
                }
-               if ((*r)->is_listenbus ()) {
+               if ((*r)->is_foldbackbus ()) {
                        continue;
                }
                if (_route->internal_send_for (*r)) {
@@ -2070,7 +2070,7 @@ ProcessorBox::build_possible_listener_menu ()
                return 0;
        }
 
-       if (_route->is_monitor () || _route->is_listenbus ()) {
+       if (_route->is_monitor () || _route->is_foldbackbus ()) {
                return 0;
        }
 
@@ -2083,7 +2083,7 @@ ProcessorBox::build_possible_listener_menu ()
                        /* don't allow sending to master or monitor or to self */
                        continue;
                }
-               if (!(*r)->is_listenbus ()) {
+               if (!(*r)->is_foldbackbus ()) {
                        continue;
                }
                if (_route->internal_send_for (*r)) {
@@ -2106,7 +2106,7 @@ ProcessorBox::build_possible_remove_listener_menu ()
                return 0;
        }
 
-       if (_route->is_monitor () || _route->is_listenbus ()) {
+       if (_route->is_monitor () || _route->is_foldbackbus ()) {
                return 0;
        }
 
@@ -2119,7 +2119,7 @@ ProcessorBox::build_possible_remove_listener_menu ()
                        /* don't allow sending to master or monitor or to self */
                        continue;
                }
-               if (!(*r)->is_listenbus ()) {
+               if (!(*r)->is_foldbackbus ()) {
                        continue;
                }
                if (!_route->internal_send_for (*r)) {
@@ -2192,8 +2192,8 @@ ProcessorBox::show_processor_menu (int arg)
                }
        }
 
-       ActionManager::get_action (X_("ProcessorMenu"), "newinsert")->set_sensitive (!_route->is_monitor () && !_route->is_listenbus ());
-       ActionManager::get_action (X_("ProcessorMenu"), "newsend")->set_sensitive (!_route->is_monitor () && !_route->is_listenbus ());
+       ActionManager::get_action (X_("ProcessorMenu"), "newinsert")->set_sensitive (!_route->is_monitor () && !_route->is_foldbackbus ());
+       ActionManager::get_action (X_("ProcessorMenu"), "newsend")->set_sensitive (!_route->is_monitor () && !_route->is_foldbackbus ());
 
        ProcessorEntry* single_selection = 0;
        if (processor_display.selection().size() == 1) {
@@ -2718,7 +2718,7 @@ ProcessorBox::choose_aux (boost::weak_ptr<Route> wr)
                return;
        }
 
-       if (target->is_listenbus ()) {
+       if (target->is_foldbackbus ()) {
                _route->add_foldback_send (target);
        } else {
                _session->add_internal_send (target, _placement, _route);
index 41e11d9ba82cdc7ab99d30fea1b190c4579a11fb..de728138cc87ed19c0ed161eece95f5b5ec77b0e 100644 (file)
@@ -118,18 +118,18 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful
                /* single bit indicates that the group order is set */
                OrderSet = 0x400,
                /* bus type for monitor mixes */
-               ListenBus = 0x2000,
+               FoldbackBus = 0x2000,
 
                /* special mask to delect out "state" bits */
                StatusMask = (Hidden),
                /* special mask to delect select type bits */
-               TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner|ListenBus)
+               TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner|FoldbackBus)
        };
 
        static const Flag AllStripables; /* mask to use for any route or VCA (but not auditioner) */
-       static const Flag MixerStripables; /* mask to use for any route or VCA (but not auditioner or Listenbus) */
+       static const Flag MixerStripables; /* mask to use for any route or VCA (but not auditioner or foldbackbus) */
        static const Flag AllRoutes; /* mask to use for any route include master+monitor, but not auditioner */
-       static const Flag MixerRoutes; /* mask to use for any route include master+monitor, but not auditioner or ListenBus*/
+       static const Flag MixerRoutes; /* mask to use for any route include master+monitor, but not auditioner or foldbackbus*/
        static const Flag Route;     /* mask for any route (bus or track */
        static const Flag Track;     /* mask to use for any track */
        static const Flag Bus;       /* mask to use for any bus */
index 4ba7532d9afa3ab7287064b676189b43e3fe528d..db65329ee8ca96f7483c73a8130bfa72bcabcb02 100644 (file)
@@ -74,7 +74,7 @@ class LIBARDOUR_API Stripable : public SessionObject,
        bool is_private_route() const { return is_auditioner(); }
        bool is_master() const { return _presentation_info.flags() & PresentationInfo::MasterOut; }
        bool is_monitor() const { return _presentation_info.flags() & PresentationInfo::MonitorOut; }
-       bool is_listenbus() const { return _presentation_info.flags() & PresentationInfo::ListenBus; }
+       bool is_foldbackbus() const { return _presentation_info.flags() & PresentationInfo::FoldbackBus; }
 
        int set_state (XMLNode const&, int);
 
index 28c59af7dbcbf61dfd509f48dd1eea8bda4b6e8e..853391c3d9d6fe55ec840d41983ecc0efa28e03d 100644 (file)
@@ -735,7 +735,7 @@ setup_enum_writer ()
        REGISTER_CLASS_ENUM (PresentationInfo, Auditioner);
        REGISTER_CLASS_ENUM (PresentationInfo, Hidden);
        REGISTER_CLASS_ENUM (PresentationInfo, OrderSet);
-       REGISTER_CLASS_ENUM (PresentationInfo, ListenBus);
+       REGISTER_CLASS_ENUM (PresentationInfo, FoldbackBus);
        REGISTER_BITS (_PresentationInfo_Flag);
 
        REGISTER_CLASS_ENUM (MusicalMode,Dorian);
index 19c583081974216034f869c5be2ebb28524a44b9..1e0c99fc60fa8f8685131245d5dcfc1ae0ca7e0b 100644 (file)
@@ -115,7 +115,7 @@ const PresentationInfo::order_t PresentationInfo::max_order = UINT32_MAX;
 const PresentationInfo::Flag PresentationInfo::Bus = PresentationInfo::Flag (PresentationInfo::AudioBus|PresentationInfo::MidiBus);
 const PresentationInfo::Flag PresentationInfo::Track = PresentationInfo::Flag (PresentationInfo::AudioTrack|PresentationInfo::MidiTrack);
 const PresentationInfo::Flag PresentationInfo::Route = PresentationInfo::Flag (PresentationInfo::Bus|PresentationInfo::Track);
-const PresentationInfo::Flag PresentationInfo::AllRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut|PresentationInfo::ListenBus);
+const PresentationInfo::Flag PresentationInfo::AllRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut|PresentationInfo::FoldbackBus);
 const PresentationInfo::Flag PresentationInfo::MixerRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut);
 const PresentationInfo::Flag PresentationInfo::AllStripables = PresentationInfo::Flag (PresentationInfo::AllRoutes|PresentationInfo::VCA);
 const PresentationInfo::Flag PresentationInfo::MixerStripables = PresentationInfo::Flag (PresentationInfo::MixerRoutes|PresentationInfo::VCA);
index 235eb1451a0653239ecb93bb581555acdf95edd8..ad2f04af61fd620c054269f0bc04cee025e0c2c9 100644 (file)
@@ -3257,7 +3257,7 @@ Session::new_audio_route (int input_channels, int output_channels, RouteGroup* r
                StateProtector sp (this);
                if (Profile->get_trx()) {
                        add_routes (ret, false, false, false, order);
-               } else if (flags == PresentationInfo::ListenBus) {
+               } else if (flags == PresentationInfo::FoldbackBus) {
                        add_routes (ret, false, false, true, order); // no autoconnect
                } else {
                        add_routes (ret, false, true, true, order); // autoconnect // outputs only
index 691107f538fb51eb71fff42269ea7ab1f6ea446e..08b8fb9c185ea31a48282eed2c586f74565f1c95 100644 (file)
@@ -4275,7 +4275,7 @@ OSC::sel_comment (char *newcomment, lo_message msg) {
 }
 
 int
-OSC::sel_new_personal_send (char *listener, lo_message msg)
+OSC::sel_new_personal_send (char *foldback, lo_message msg)
 {
        OSCSurface *sur = get_surface(get_address (msg));
        boost::shared_ptr<Stripable> s;
@@ -4288,24 +4288,24 @@ OSC::sel_new_personal_send (char *listener, lo_message msg)
                        return -1;
                }
        }
-       /* if a listenbus called listener exists use it
-        * other wise create create it. Then create a personal send from
+       /* if a foldbackbus called foldback exists use it
+        * other wise create create it. Then create a foldback send from
         * this route to that bus.
         */
-       string listenbus = listener;
-       string listen_name = listenbus;
-       if (listenbus.find ("- monitor") == string::npos) {
-               listen_name = string_compose ("%1 - monitor", listenbus);
+       string foldbackbus = foldback;
+       string foldback_name = foldbackbus;
+       if (foldbackbus.find ("- monitor") == string::npos) {
+               foldback_name = string_compose ("%1 - monitor", foldbackbus);
        }
-       boost::shared_ptr<Route> lsn_rt = session->route_by_name (listen_name);
+       boost::shared_ptr<Route> lsn_rt = session->route_by_name (foldback_name);
        if (!lsn_rt) {
-               // doesn't exist but check if raw name does and is listenbus
-               boost::shared_ptr<Route> raw_rt = session->route_by_name (listenbus);
-               if (raw_rt && raw_rt->is_listenbus()) {
+               // doesn't exist but check if raw name does and is foldbackbus
+               boost::shared_ptr<Route> raw_rt = session->route_by_name (foldbackbus);
+               if (raw_rt && raw_rt->is_foldbackbus()) {
                        lsn_rt = raw_rt;
                } else {
-                       // create the listenbus
-                       RouteList list = session->new_audio_route (2, 2, 0, 1, listen_name, PresentationInfo::ListenBus, (uint32_t) -1);
+                       // create the foldbackbus
+                       RouteList list = session->new_audio_route (2, 2, 0, 1, foldback_name, PresentationInfo::FoldbackBus, (uint32_t) -1);
                        lsn_rt = *(list.begin());
                        lsn_rt->presentation_info().set_hidden (true);
                        session->set_dirty();
@@ -4329,7 +4329,7 @@ OSC::sel_new_personal_send (char *listener, lo_message msg)
                        PBD::warning << "OSC: new_send - can't send to self." << endmsg;
                }
        } else {
-               PBD::warning << "OSC: new_send - no ListenBus to send to." << endmsg;
+               PBD::warning << "OSC: new_send - no FoldbackBus to send to." << endmsg;
        }
 
        return -1;
@@ -6349,7 +6349,7 @@ OSC::get_sorted_stripables(std::bitset<32> types, bool cue, uint32_t custom, Sor
                                sorted.push_back (s);
                        } else if (types[4] && boost::dynamic_pointer_cast<VCA>(s)) {
                                sorted.push_back (s);
-                       } else  if (s->is_listenbus()) {
+                       } else  if (s->is_foldbackbus()) {
                                if (types[7]) {
                                        sorted.push_back (s);
                                }
@@ -6570,7 +6570,7 @@ OSC::cue_new_aux (string name, string dest_1, string dest_2, lo_message msg)
        RouteList list;
        boost::shared_ptr<Stripable> aux;
        name = string_compose ("%1 - monitor", name);
-       list = session->new_audio_route (2, 2, 0, 1, name, PresentationInfo::ListenBus, (uint32_t) -1);
+       list = session->new_audio_route (2, 2, 0, 1, name, PresentationInfo::FoldbackBus, (uint32_t) -1);
        aux = *(list.begin());
        if (aux) {
                boost::shared_ptr<Route> r = boost::dynamic_pointer_cast<Route>(aux);