diff --git a/gtk2_ardour/ardour.keys.in b/gtk2_ardour/ardour.keys.in index dea619a011..85e5f503fe 100644 --- a/gtk2_ardour/ardour.keys.in +++ b/gtk2_ardour/ardour.keys.in @@ -498,5 +498,8 @@ This mode provides many different operations on both regions and control points, @notes|Notes/invert-selection| <@PRIMARY@>i|Invert note selection @notes|Notes/duplicate-selection| <@PRIMARY@>d|Duplicate note selection -@rec|Recorder/arm-all| <@PRIMARY@>r|record arm all tracks -@rec|Recorder/arm-none| <@PRIMARY@><@TERTIARY@>r|disable record arm of all tracks +@rec|Recorder/arm-all| <@PRIMARY@>r|record arm all tracks +@rec|Recorder/arm-none| <@PRIMARY@><@TERTIARY@>r|disable record arm of all tracks +@rec|Recorder/rec-undo| <@PRIMARY@>z|undo +@rec|Recorder/rec-redo| <@PRIMARY@><@TERTIARY@>z|redo +@rec|Recorder/alternate-rec-redo| <@PRIMARY@>y|redo diff --git a/gtk2_ardour/recorder_ui.cc b/gtk2_ardour/recorder_ui.cc index 89afef6f4f..cbee56d0b1 100644 --- a/gtk2_ardour/recorder_ui.cc +++ b/gtk2_ardour/recorder_ui.cc @@ -393,6 +393,9 @@ RecorderUI::register_actions () ActionManager::register_action (group, "reset-input-peak-hold", _("Reset Input Peak Hold"), sigc::mem_fun (*this, &RecorderUI::peak_reset)); ActionManager::register_action (group, "arm-all", _("Record Arm All Tracks"), sigc::mem_fun (*this, &RecorderUI::arm_all)); ActionManager::register_action (group, "arm-none", _("Disable Record Arm of All Tracks"), sigc::mem_fun (*this, &RecorderUI::arm_none)); + ActionManager::register_action (group, "rec-undo", _("Undo"), sigc::mem_fun (*this, &RecorderUI::rec_undo)); + ActionManager::register_action (group, "rec-redo", _("Redo"), sigc::mem_fun (*this, &RecorderUI::rec_redo)); + ActionManager::register_action (group, "alternate-rec-redo", _("Redo"), sigc::mem_fun (*this, &RecorderUI::rec_redo)); } void @@ -1347,6 +1350,22 @@ RecorderUI::arm_none () } } +void +RecorderUI::rec_undo () +{ + if (_session) { + _session->undo (1); + } +} + +void +RecorderUI::rec_redo () +{ + if (_session) { + _session->redo (1); + } +} + void RecorderUI::peak_reset () { diff --git a/gtk2_ardour/recorder_ui.h b/gtk2_ardour/recorder_ui.h index 2bd833609d..50d96badcc 100644 --- a/gtk2_ardour/recorder_ui.h +++ b/gtk2_ardour/recorder_ui.h @@ -114,6 +114,10 @@ private: void arm_all (); void arm_none (); + + void rec_undo (); + void rec_redo (); + void peak_reset (); void update_sensitivity ();