summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_canvas_events.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2016-05-25 02:46:57 +0200
committerRobin Gareus <robin@gareus.org>2016-05-25 02:46:57 +0200
commitcec449871ea105f090e948dbe6ec39c6ca115d55 (patch)
tree51174a966e551c7d67d569c94f2ed5da358965d2 /gtk2_ardour/editor_canvas_events.cc
parentb487954722d72fde26689e442ce737a35cf17081 (diff)
fix region gain via range tool
Moving the mouse over another region's gain line changed clicked_regionview. clicked_regionview is used along with range-time when initiating an AutomationRangeDrag.
Diffstat (limited to 'gtk2_ardour/editor_canvas_events.cc')
-rw-r--r--gtk2_ardour/editor_canvas_events.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/gtk2_ardour/editor_canvas_events.cc b/gtk2_ardour/editor_canvas_events.cc
index 6eb017134d..8788717bd1 100644
--- a/gtk2_ardour/editor_canvas_events.cc
+++ b/gtk2_ardour/editor_canvas_events.cc
@@ -677,10 +677,14 @@ Editor::canvas_line_event (GdkEvent *event, ArdourCanvas::Item* item, Automation
AudioRegionGainLine* gl;
if ((gl = dynamic_cast<AudioRegionGainLine*> (al)) != 0) {
type = GainLineItem;
- clicked_regionview = &gl->region_view ();
+ if (event->type == GDK_BUTTON_PRESS) {
+ clicked_regionview = &gl->region_view ();
+ }
} else {
type = AutomationLineItem;
- clicked_regionview = 0;
+ if (event->type == GDK_BUTTON_PRESS) {
+ clicked_regionview = 0;
+ }
}
clicked_control_point = 0;