mirror of https://github.com/buggins/dlangui.git
fix crash on redo; fix redo and delete line shortcuts
This commit is contained in:
parent
4ffd0af922
commit
45b1fa3bd1
|
@ -1251,7 +1251,7 @@ class EditableContent {
|
||||||
|
|
||||||
/// redoes last undone change
|
/// redoes last undone change
|
||||||
bool redo(Object source) {
|
bool redo(Object source) {
|
||||||
if (!hasUndo)
|
if (!hasRedo)
|
||||||
return false;
|
return false;
|
||||||
if (_readOnly)
|
if (_readOnly)
|
||||||
throw new Exception("content is readonly");
|
throw new Exception("content is readonly");
|
||||||
|
|
|
@ -376,7 +376,8 @@ class EditWidgetBase : ScrollWidgetBase, EditableContentListener, MenuItemAction
|
||||||
|
|
||||||
new Action(EditorActions.ToggleLineComment, KeyCode.KEY_DIVIDE, KeyFlag.Control),
|
new Action(EditorActions.ToggleLineComment, KeyCode.KEY_DIVIDE, KeyFlag.Control),
|
||||||
new Action(EditorActions.ToggleBlockComment, KeyCode.KEY_DIVIDE, KeyFlag.Control | KeyFlag.Shift),
|
new Action(EditorActions.ToggleBlockComment, KeyCode.KEY_DIVIDE, KeyFlag.Control | KeyFlag.Shift),
|
||||||
new Action(EditorActions.DeleteLine, KeyCode.KEY_Y, KeyFlag.Control),
|
new Action(EditorActions.DeleteLine, KeyCode.KEY_D, KeyFlag.Control),
|
||||||
|
new Action(EditorActions.DeleteLine, KeyCode.KEY_L, KeyFlag.Control),
|
||||||
new Action(EditorActions.InsertLine, KeyCode.RETURN, KeyFlag.Control),
|
new Action(EditorActions.InsertLine, KeyCode.RETURN, KeyFlag.Control),
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue