|
@@ -1208,18 +1208,18 @@ window_.on(DOM.Events.Load, (e) => {
|
|
|
window_.on(DOM.Events.KeyDown, (e) => {
|
|
|
if(Class.isPackage)
|
|
|
return;
|
|
|
- if(window.page && (e.ctrlKey || e.metaKey))
|
|
|
+ if(window.page && (e.key === DOM.Keys.Control || e.key === DOM.Keys.Meta))
|
|
|
window.page.codeMirrorEditorElement.addClass(ClassPage.StyleClasses.CtrlPressed);
|
|
|
- if(window.page && e.shiftKey)
|
|
|
+ if(window.page && e.key === DOM.Keys.Shift)
|
|
|
window.page.codeMirrorEditorElement.addClass(ClassPage.StyleClasses.ShiftPressed);
|
|
|
});
|
|
|
|
|
|
window_.on(DOM.Events.KeyUp, (e) => {
|
|
|
if(Class.isPackage)
|
|
|
return;
|
|
|
- if(window.page && (e.ctrlKey || e.metaKey))
|
|
|
+ if(window.page && (e.key === DOM.Keys.Control || e.key === DOM.Keys.Meta))
|
|
|
window.page.codeMirrorEditorElement.removeClass(ClassPage.StyleClasses.CtrlPressed);
|
|
|
- if(window.page && e.shiftKey)
|
|
|
+ if(window.page && e.key === DOM.Keys.Shift)
|
|
|
window.page.codeMirrorEditorElement.removeClass(ClassPage.StyleClasses.ShiftPressed);
|
|
|
});
|
|
|
|