diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2009-11-19 21:49:42 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2009-11-19 21:49:42 +0000 |
commit | 648450781b8e5a39fd89c1a42f34b601c97df0e2 (patch) | |
tree | 46d46db6f0310f1f265e9a5faf402df20bd83352 | |
parent | 23c79d85035d925536c8beed0064b7867137dfd6 (diff) |
reset aux send menu item as appropriate; make sure that Aux role for any delivery object is saved/restored correctly
git-svn-id: svn://localhost/ardour2/branches/3.0@6135 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r-- | gtk2_ardour/processor_box.cc | 5 | ||||
-rw-r--r-- | libs/ardour/enums.cc | 1 |
2 files changed, 4 insertions, 2 deletions
diff --git a/gtk2_ardour/processor_box.cc b/gtk2_ardour/processor_box.cc index bd84d4ca0a..7b784022fa 100644 --- a/gtk2_ardour/processor_box.cc +++ b/gtk2_ardour/processor_box.cc @@ -293,6 +293,7 @@ Gtk::Menu* ProcessorBox::build_possible_aux_menu () { boost::shared_ptr<RouteList> rl = _session.get_routes_with_internal_returns(); + if (rl->empty()) { return 0; } @@ -301,7 +302,6 @@ ProcessorBox::build_possible_aux_menu () Menu* menu = manage (new Menu); MenuList& items = menu->items(); - for (RouteList::iterator r = rl->begin(); r != rl->end(); ++r) { if (!(*r)->internal_send_for (*r)) { items.push_back (MenuElem ((*r)->name(), bind (sigc::ptr_fun (ProcessorBox::rb_choose_aux), boost::weak_ptr<Route>(*r)))); @@ -341,7 +341,8 @@ ProcessorBox::show_processor_menu (gint arg) if (m) { aux_menu_item->set_submenu (*m); } else { - /* XXX WHAT?*/ + /* stupid gtkmm: we need to pass a null reference here */ + aux_menu_item->set_submenu (*((Gtk::Menu *)0)); } } diff --git a/libs/ardour/enums.cc b/libs/ardour/enums.cc index 4b0ec3b343..72aa5bef55 100644 --- a/libs/ardour/enums.cc +++ b/libs/ardour/enums.cc @@ -515,6 +515,7 @@ setup_enum_writer () REGISTER_CLASS_ENUM (Delivery, Send); REGISTER_CLASS_ENUM (Delivery, Listen); REGISTER_CLASS_ENUM (Delivery, Main); + REGISTER_CLASS_ENUM (Delivery, Aux); REGISTER_BITS (_Delivery_Role); REGISTER_CLASS_ENUM (MuteMaster, PreFader); |