Browse Source

Fix error thrown by Ctrl/Cmd+I in the console

Shaddock Heath 9 years ago
parent
commit
83a2654f3e
1 changed files with 3 additions and 2 deletions
  1. 3 2
      Script/AtomicWebViewEditor/editor/editorCommands.ts

+ 3 - 2
Script/AtomicWebViewEditor/editor/editorCommands.ts

@@ -56,9 +56,10 @@ export function configure(fileExt: string, filename: string) {
         filename: filename,
         editor: monacoEditor
     });
-    
+
     // Override CMD/CTRL+I since that is going to be used for Format Code and in the editor it is assigned to something else
-    monacoEditor.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KEY_I, null, null);
+    const noOpCommand: monaco.editor.ICommandHandler = () => { };
+    monacoEditor.addCommand(monaco.KeyMod.CtrlCmd | monaco.KeyCode.KEY_I, noOpCommand, null);
 
 }