Change undo keybindings

This commit is contained in:
Tom Willemse 2017-06-06 21:35:34 -07:00
parent 0ac73d412f
commit a565d2e851

View file

@ -118,10 +118,6 @@ key.setGlobalKey(["C-x", "K"], function (ev) {
closeWindow(true);
}, 'Close the window', false);
key.setGlobalKey(["C-c", "u"], function (ev) {
undoCloseTab();
}, 'Undo closed tab', false);
key.setGlobalKey(["C-x", "n"], function (ev) {
OpenBrowserWindow();
}, 'Open new window', false);
@ -502,6 +498,19 @@ key.setCaretKey('M-n', function (ev) {
}, 'Focus to the previous button', false);
// In the view context, make undo about tabs.
key.setViewKey([["C-/"], ["C-x", "u"], ["C-_"]], function (ev) {
undoCloseTab();
}, 'Undo closed tab', false);
// In the edit conext, make undo about text.
key.setEditKey([["C-/"], ["C-x", "u"], ["C-_"]], function (ev) {
display.echoStatusBar("Undo!", 2000);
goDoCommand("cmd_undo");
}, 'Undo', false);
//////////////
// HoK Keys //
//////////////