Allow single click to create Region-Gain points (again)
regression was introduced in 18819a48a9
This commit is contained in:
parent
b962addc8c
commit
f78d82a192
|
@ -1881,24 +1881,19 @@ Editor::button_release_handler (ArdourCanvas::Item* item, GdkEvent* event, ItemT
|
||||||
switch (item_type) {
|
switch (item_type) {
|
||||||
case RegionItem:
|
case RegionItem:
|
||||||
{
|
{
|
||||||
/* check that we didn't drag before releasing, since
|
printf ("RegionItem\n");
|
||||||
its really annoying to create new control
|
/* since we have FreehandLineDrag we can only get here after a drag, when no movement has happend */
|
||||||
points when doing this.
|
assert (were_dragging);
|
||||||
*/
|
|
||||||
AudioRegionView* arv = dynamic_cast<AudioRegionView*> (clicked_regionview);
|
AudioRegionView* arv = dynamic_cast<AudioRegionView*> (clicked_regionview);
|
||||||
|
AutomationRegionView* atv = dynamic_cast<AutomationRegionView*> (clicked_regionview);
|
||||||
|
|
||||||
if (!were_dragging) {
|
|
||||||
if (arv) {
|
if (arv) {
|
||||||
bool with_guard_points = Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier);
|
bool with_guard_points = Keyboard::modifier_state_equals (event->button.state, Keyboard::PrimaryModifier);
|
||||||
arv->add_gain_point_event (item, event, with_guard_points);
|
arv->add_gain_point_event (item, event, with_guard_points);
|
||||||
}
|
} else if (atv) {
|
||||||
} else {
|
|
||||||
AutomationRegionView* atv = dynamic_cast<AutomationRegionView*> (clicked_regionview);
|
|
||||||
|
|
||||||
if (atv) {
|
|
||||||
atv->add_automation_event (event);
|
atv->add_automation_event (event);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user