Merge duplicated code.
This commit is contained in:
parent
8b47241596
commit
ba9a90b927
@ -758,7 +758,7 @@ MidiRegionView::key_press (GdkEventKey* ev)
|
||||
delete_selection();
|
||||
return true;
|
||||
|
||||
} else if (ev->keyval == GDK_Tab) {
|
||||
} else if (ev->keyval == GDK_Tab || ev->keyval == GDK_ISO_Left_Tab) {
|
||||
|
||||
trackview.editor().begin_reversible_selection_op (_("Select Adjacent Note"));
|
||||
|
||||
@ -772,24 +772,6 @@ MidiRegionView::key_press (GdkEventKey* ev)
|
||||
|
||||
return true;
|
||||
|
||||
} else if (ev->keyval == GDK_ISO_Left_Tab) {
|
||||
|
||||
/* Shift-TAB generates ISO Left Tab, for some reason */
|
||||
|
||||
trackview.editor().begin_reversible_selection_op (_("Select Adjacent Note"));
|
||||
|
||||
if (Keyboard::modifier_state_contains (ev->state, Keyboard::PrimaryModifier)) {
|
||||
goto_previous_note (Keyboard::modifier_state_contains (ev->state, Keyboard::TertiaryModifier));
|
||||
} else {
|
||||
goto_next_note (Keyboard::modifier_state_contains (ev->state, Keyboard::TertiaryModifier));
|
||||
}
|
||||
|
||||
trackview.editor().commit_reversible_selection_op();
|
||||
|
||||
return true;
|
||||
|
||||
|
||||
|
||||
} else if (ev->keyval == GDK_Up) {
|
||||
|
||||
bool allow_smush = Keyboard::modifier_state_contains (ev->state, Keyboard::TertiaryModifier);
|
||||
|
Loading…
Reference in New Issue
Block a user