diff --git a/gtk2_ardour/piano_roll_header.cc b/gtk2_ardour/piano_roll_header.cc index 59e6f54fa2..e39f70c6cb 100644 --- a/gtk2_ardour/piano_roll_header.cc +++ b/gtk2_ardour/piano_roll_header.cc @@ -661,9 +661,11 @@ PianoRollHeader::on_button_press_event (GdkEventButton* ev) } else { int note = _view.y_to_note(ev->y); bool tertiary = Keyboard::modifier_state_contains (ev->state, Keyboard::TertiaryModifier); + bool primary = Keyboard::modifier_state_contains (ev->state, Keyboard::PrimaryModifier); + bool toggle = (ev->state == GDK_CONTROL_MASK); - if (ev->state == GDK_CONTROL_MASK){ - if (ev->type == GDK_2BUTTON_PRESS) { + if (ev->type == GDK_2BUTTON_PRESS) { + if (primary) { _adj.set_value (0.0); _adj.set_page_size (127.0); _adj.value_changed (); @@ -677,6 +679,9 @@ PianoRollHeader::on_button_press_event (GdkEventButton* ev) } else if (tertiary && (ev->button == 1 || ev->button == 2)) { ExtendNoteSelection (note); // EMIT SIGNAL return true; + } else if (toggle && (ev->button == 1 || ev->button == 2)) { + ToggleNoteSelection (note); // EMIT SIGNAL + return true; } else if (ev->button == 1 && note >= 0 && note < 128) { add_modal_grab(); _dragging = true;