Fix crash on clear option for automation tracks (#3195). Also fix state change signa...
authorCarl Hetherington <carl@carlh.net>
Thu, 27 May 2010 12:26:00 +0000 (12:26 +0000)
committerCarl Hetherington <carl@carlh.net>
Thu, 27 May 2010 12:26:00 +0000 (12:26 +0000)
git-svn-id: svn://localhost/ardour2/branches/3.0@7178 d708f5d6-7413-0410-9779-e7cbd77b26cf

gtk2_ardour/automation_time_axis.cc
libs/ardour/automation_list.cc
libs/evoral/src/ControlList.cpp

index 51923089ad6084b586c408e55f64a092741582bb..9163b10dc1bea5e952d791c03069b596dbc91767 100644 (file)
@@ -385,11 +385,10 @@ AutomationTimeAxisView::set_interpolation (AutomationList::InterpolationStyle st
 void
 AutomationTimeAxisView::clear_clicked ()
 {
-       _session->begin_reversible_command (_("clear automation"));
        if (_line) {
+               _session->begin_reversible_command (_("clear automation"));
                _line->clear ();
        }
-       _session->commit_reversible_command ();
 }
 
 void
index b6de006d32c746b9dfc6705a550fd9b896b0e613..f34104ce2228a29b1a17f9688434f23f793eeadc 100644 (file)
@@ -338,7 +338,7 @@ AutomationList::deserialize_events (const XMLNode& node)
                maybe_signal_changed ();
        }
 
-        ControlList::thaw ();
+        thaw ();
         
        return 0;
 }
@@ -391,7 +391,7 @@ AutomationList::set_state (const XMLNode& node, int version)
                        fast_simple_add (x, y);
                }
 
-                ControlList::thaw ();
+                thaw ();
 
                return 0;
        }
index 9079453f1c8f72c5c328bc15307f5852870841dc..00b876d18a14a2097ac2197568e96d769a130b25 100644 (file)
@@ -167,8 +167,9 @@ ControlList::maybe_signal_changed ()
 {
        mark_dirty ();
 
-       if (_frozen)
+       if (_frozen) {
                _changed_when_thawed = true;
+       }
 }
 
 void