[Summary] Changed function name update_route_active_state() on update_route_record_st...
authornikolay <MPolianovskyi@wavesglobal.com>
Fri, 19 Sep 2014 13:45:01 +0000 (16:45 +0300)
committerPaul Davis <paul@linuxaudiosystems.com>
Mon, 29 Jun 2015 18:18:10 +0000 (14:18 -0400)
[Reviewed] GZharun

Conflicts:
libs/ardour/ardour/session.h
libs/ardour/session.cc
libs/ardour/session_state.cc

libs/ardour/ardour/session.h
libs/ardour/session.cc
libs/ardour/session_state.cc

index bdb3c3f7921cf9a5d8e4363d0f60ab22d249470a..2a90230c73d5d8250b992f1850a3e2b033959ce9 100644 (file)
@@ -1677,9 +1677,9 @@ class LIBARDOUR_API Session : public PBD::StatefulDestructible, public PBD::Scop
 
        mutable bool have_looped; ///< Used in ::audible_frame(*)
 
-       void update_have_rec_enabled_track ();
+       void update_route_record_state ();
        gint _have_rec_enabled_track;
-    gint _have_rec_disabled_track;
+       gint _have_rec_disabled_track;
 
        static int ask_about_playlist_deletion (boost::shared_ptr<Playlist>);
 
index dc00ecd8932571b26bd0ae87daee9c424103597c..94153de1cfacb5954db83669fbb7f9451e538d6a 100644 (file)
@@ -2709,6 +2709,8 @@ Session::add_routes (RouteList& new_routes, bool input_auto_connect, bool output
        
        reassign_track_numbers();
 
+       update_route_record_state ();
+    
        RouteAdded (new_routes); /* EMIT SIGNAL */
 }
 
@@ -2766,7 +2768,7 @@ Session::add_routes_inner (RouteList& new_routes, bool input_auto_connect, bool
                if (tr) {
                        tr->PlaylistChanged.connect_same_thread (*this, boost::bind (&Session::track_playlist_changed, this, boost::weak_ptr<Track> (tr)));
                        track_playlist_changed (boost::weak_ptr<Track> (tr));
-                       tr->RecordEnableChanged.connect_same_thread (*this, boost::bind (&Session::update_have_rec_enabled_track, this));
+                       tr->RecordEnableChanged.connect_same_thread (*this, boost::bind (&Session::update_route_record_state, this));
 
                        boost::shared_ptr<MidiTrack> mt = boost::dynamic_pointer_cast<MidiTrack> (tr);
                        if (mt) {
@@ -2994,6 +2996,8 @@ Session::remove_route (boost::shared_ptr<Route> route)
                save_history (_current_snapshot_name);
        }
        reassign_track_numbers();
+    
+       update_route_record_state ();
 }
 
 void
@@ -4986,7 +4990,7 @@ Session::have_rec_disabled_track () const
 
 /** Update the state of our rec-enabled tracks flag */
 void
-Session::update_have_rec_enabled_track ()
+Session::update_route_record_state ()
 {
        boost::shared_ptr<RouteList> rl = routes.reader ();
        RouteList::iterator i = rl->begin();
@@ -5063,7 +5067,8 @@ Session::route_added_to_route_group (RouteGroup* rg, boost::weak_ptr<Route> r)
 void
 Session::route_removed_from_route_group (RouteGroup* rg, boost::weak_ptr<Route> r)
 {
-       RouteRemovedFromRouteGroup (rg, r);
+       update_route_record_state ();
+       RouteRemovedFromRouteGroup (rg, r); /* EMIT SIGNAL */
 }
 
 boost::shared_ptr<RouteList>
index 4810e6935bbdb5b3a822675d2d693859c24122ee..a124f4fc12e4f389f73469e701277931e160c942 100644 (file)
@@ -1350,7 +1350,7 @@ Session::set_state (const XMLNode& node, int version)
                ControlProtocolManager::instance().set_state (*child, version);
        }
 
-       update_have_rec_enabled_track ();
+       update_route_record_state ();
 
        /* here beginneth the second phase ... */