diff options
author | Carl Hetherington <carl@carlh.net> | 2011-09-07 13:45:52 +0000 |
---|---|---|
committer | Carl Hetherington <carl@carlh.net> | 2011-09-07 13:45:52 +0000 |
commit | 3ba6804f27f43fe968884351762173313063b865 (patch) | |
tree | 0bc26627e9f25b12dba77ca123642f7849c4ffc1 /gtk2_ardour/editor_mouse.cc | |
parent | 10e1807fba8e9c4aa543b8caced2fdf506990723 (diff) |
Don't create new regions on clicks on MIDI plugin automation
tracks (#4298).
git-svn-id: svn://localhost/ardour2/branches/3.0@10062 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour/editor_mouse.cc')
-rw-r--r-- | gtk2_ardour/editor_mouse.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gtk2_ardour/editor_mouse.cc b/gtk2_ardour/editor_mouse.cc index 0e1278ab1f..4816c2e04c 100644 --- a/gtk2_ardour/editor_mouse.cc +++ b/gtk2_ardour/editor_mouse.cc @@ -881,7 +881,9 @@ Editor::button_press_handler_1 (ArdourCanvas::Item* item, GdkEvent* event, ItemT case AutomationTrackItem: { TimeAxisView* parent = clicked_axisview->get_parent (); - if (parent && dynamic_cast<MidiTimeAxisView*> (parent)) { + AutomationTimeAxisView* atv = dynamic_cast<AutomationTimeAxisView*> (clicked_axisview); + assert (atv); + if (parent && dynamic_cast<MidiTimeAxisView*> (parent) && atv->show_regions ()) { /* create a MIDI region so that we have somewhere to put automation */ _drags->set (new RegionCreateDrag (this, item, parent), event); } else { |