fixup cherry-picked changes from Waves Tracks, and fix for Ardour
authorPaul Davis <paul@linuxaudiosystems.com>
Fri, 6 Feb 2015 01:26:02 +0000 (20:26 -0500)
committerPaul Davis <paul@linuxaudiosystems.com>
Fri, 6 Feb 2015 01:26:02 +0000 (20:26 -0500)
gtk2_ardour/editor_drag.cc

index d82156bfd11e4132c2e5f2857e2c6c8f95f837e2..1161d613395c2e1e738bc4cc6359ca0683b478af 100644 (file)
@@ -3550,8 +3550,15 @@ MarkerDrag::aborted (bool movement_occured)
 
                /* move all markers to their original location */
                
+
                for (vector<Marker*>::iterator m = x->markers.begin(); m != x->markers.end(); ++m) {
-                       (*m)->set_position ((*m)->location()->start(), (*m)->location()->end());
+
+                       bool is_start;
+                       Location * location = _editor->find_location_from_marker (*m, is_start);
+
+                       if (location) {
+                               (*m)->set_position (is_start ? location->start() : location->end());
+                       }
                }
        }
 }
@@ -4726,7 +4733,6 @@ void
 RangeMarkerBarDrag::aborted (bool movement_occured)
 {
        if (movement_occured) {
-               _crect->hide ();
                _drag_rect->hide ();
        }
 }
@@ -5497,9 +5503,9 @@ void
 CrossfadeEdgeDrag::aborted (bool)
 {
        if (start) {
-               arv->redraw_start_xfade ();
+               // arv->redraw_start_xfade ();
        } else {
-               arv->redraw_end_xfade ();
+               // arv->redraw_end_xfade ();
        }
 }