summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_actions.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2014-06-24 09:56:08 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2014-06-24 09:56:16 -0400
commitf147846863c27dfa13ef83b696f198a5092721fa (patch)
treef52baa144cf760138c862f7cdc4ab8fd80a1159d /gtk2_ardour/editor_actions.cc
parentdae3b26f188c17b1e74c17284539979a92ea630f (diff)
add ability to save current action sensitivities and restore them, and to disable all action sensitivity.
This is needed to be able to lock the application fully on OS X, where the global menu bar would still allow interaction even when a modal dialog is displayed.
Diffstat (limited to 'gtk2_ardour/editor_actions.cc')
-rw-r--r--gtk2_ardour/editor_actions.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/gtk2_ardour/editor_actions.cc b/gtk2_ardour/editor_actions.cc
index d8889a9c81..bab2caaf8c 100644
--- a/gtk2_ardour/editor_actions.cc
+++ b/gtk2_ardour/editor_actions.cc
@@ -150,6 +150,11 @@ Editor::register_actions ()
ActionManager::register_action (editor_actions, "escape", _("Break drag or deselect all"), sigc::mem_fun (*this, &Editor::escape));
+ /* We don't bother registering "unlock" because it would be insensitive
+ when required. Editor::unlock() must be invoked directly.
+ */
+ ActionManager::register_action (editor_actions, "lock", _("Lock"), sigc::mem_fun (*this, &Editor::lock));
+
toggle_reg_sens (editor_actions, "show-editor-mixer", _("Show Editor Mixer"), sigc::mem_fun (*this, &Editor::editor_mixer_button_toggled));
toggle_reg_sens (editor_actions, "show-editor-list", _("Show Editor List"), sigc::mem_fun (*this, &Editor::editor_list_button_toggled));