diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2008-10-03 13:38:53 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2008-10-03 13:38:53 +0000 |
commit | 51f2a5fc4ee73752cb635db913769f9d47941933 (patch) | |
tree | b4485eb90967006b0dfc6fe01da5778d56f901ce /libs | |
parent | d5b13692582e014c02dff75bf85ae6765d762dc4 (diff) |
part II of probable fix for track sync-ordering
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@3851 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs')
-rw-r--r-- | libs/ardour/ardour/route.h | 2 | ||||
-rw-r--r-- | libs/ardour/ardour/session.h | 3 | ||||
-rw-r--r-- | libs/ardour/route.cc | 2 | ||||
-rw-r--r-- | libs/ardour/session.cc | 6 | ||||
-rw-r--r-- | libs/ardour/session_state.cc | 2 |
5 files changed, 9 insertions, 6 deletions
diff --git a/libs/ardour/ardour/route.h b/libs/ardour/ardour/route.h index 49ced51f88..8a3c7469b1 100644 --- a/libs/ardour/ardour/route.h +++ b/libs/ardour/ardour/route.h @@ -242,7 +242,7 @@ class Route : public IO sigc::signal<void> RemoteControlIDChanged; void sync_order_keys (); - static sigc::signal<void> SyncOrderKeys; + static sigc::signal<void,void*> SyncOrderKeys; protected: friend class Session; diff --git a/libs/ardour/ardour/session.h b/libs/ardour/ardour/session.h index 2c9ef608fe..322b1b77b2 100644 --- a/libs/ardour/ardour/session.h +++ b/libs/ardour/ardour/session.h @@ -306,6 +306,8 @@ class Session : public PBD::StatefulDestructible bool operator() (boost::shared_ptr<Route>, boost::shared_ptr<Route> b); }; + void sync_order_keys (void *src); + template<class T> void foreach_route (T *obj, void (T::*func)(Route&)); template<class T> void foreach_route (T *obj, void (T::*func)(boost::shared_ptr<Route>)); template<class T, class A> void foreach_route (T *obj, void (T::*func)(Route&, A), A arg); @@ -1751,7 +1753,6 @@ class Session : public PBD::StatefulDestructible XMLNode& get_control_protocol_state (); void set_history_depth (uint32_t depth); - void sync_order_keys (); static bool _disable_all_loaded_plugins; }; diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index 0bc9f3fff3..7056480c09 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -51,7 +51,7 @@ using namespace ARDOUR; using namespace PBD; uint32_t Route::order_key_cnt = 0; -sigc::signal<void> Route::SyncOrderKeys; +sigc::signal<void,void*> Route::SyncOrderKeys; Route::Route (Session& sess, string name, int input_min, int input_max, int output_min, int output_max, Flag flg, DataType default_type) : IO (sess, name, input_min, input_max, output_min, output_max, default_type), diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc index af0f31b1a4..7832558ca3 100644 --- a/libs/ardour/session.cc +++ b/libs/ardour/session.cc @@ -2153,6 +2153,8 @@ Session::remove_route (shared_ptr<Route> route) route->drop_references (); + sync_order_keys (this); + /* save the new state of the world */ if (save_state (_current_snapshot_name)) { @@ -4197,7 +4199,7 @@ Session::compute_initial_length () } void -Session::sync_order_keys () +Session::sync_order_keys (void* src) { if (!Config->get_sync_all_route_ordering()) { /* leave order keys as they are */ @@ -4210,5 +4212,5 @@ Session::sync_order_keys () (*i)->sync_order_keys (); } - Route::SyncOrderKeys (); // EMIT SIGNAL + Route::SyncOrderKeys (src); // EMIT SIGNAL } diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc index cecaefb179..ddb166b7ab 100644 --- a/libs/ardour/session_state.cc +++ b/libs/ardour/session_state.cc @@ -3345,7 +3345,7 @@ Session::config_changed (const char* parameter_name) } else if (PARAM_IS ("history-depth")) { set_history_depth (Config->get_history_depth()); } else if (PARAM_IS ("sync-all-route-ordering")) { - sync_order_keys (); + sync_order_keys (0); } set_dirty (); |