diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index 50c4c229ea..7d2908a18c 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -716,12 +716,11 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop /* I/O bundles */ - void add_bundle (boost::shared_ptr); + void add_bundle (boost::shared_ptr, bool emit_signal = true); void remove_bundle (boost::shared_ptr); boost::shared_ptr bundle_by_name (std::string) const; - PBD::Signal1 > BundleAdded; - PBD::Signal1 > BundleRemoved; + PBD::Signal0 BundleAddedOrRemoved; void midi_panic (); diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index b18b756e60..97346e44e7 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -4129,7 +4129,7 @@ Session::available_capture_duration () } void -Session::add_bundle (boost::shared_ptr bundle) +Session::add_bundle (boost::shared_ptr bundle, bool emit_signal) { { RCUWriter writer (_bundles); @@ -4137,7 +4137,9 @@ Session::add_bundle (boost::shared_ptr bundle) b->push_back (bundle); } - BundleAdded (bundle); /* EMIT SIGNAL */ + if (emit_signal) { + BundleAddedOrRemoved (); /* EMIT SIGNAL */ + } set_dirty(); } @@ -4159,7 +4161,7 @@ Session::remove_bundle (boost::shared_ptr bundle) } if (removed) { - BundleRemoved (bundle); /* EMIT SIGNAL */ + BundleAddedOrRemoved (); /* EMIT SIGNAL */ } set_dirty();