File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
client/modules/IDE/components Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -63,11 +63,6 @@ window.JSHINT = JSHINT;
6363window . CSSLint = CSSLint ;
6464window . HTMLHint = HTMLHint ;
6565
66-
67- // delete CodeMirror.keyMap.sublime['Shift-Cmd-F'];
68-
69- console . log ( CodeMirror . keyMap . sublime ) ;
70-
7166const IS_TAB_INDENT = false ;
7267const INDENTATION_AMOUNT = 2 ;
7368
@@ -173,7 +168,8 @@ class Editor extends React.Component {
173168 // 91 === Cmd
174169 // 16 === Shift
175170 // 70 === f
176- if ( this . map [ 91 ] && this . map [ 16 ] && this . map [ 70 ] ) {
171+ // 17 === Ctrl
172+ if ( ( ( metaKey === 'Cmd' && this . map [ 91 ] ) || ( metaKey === 'Ctrl' && this . map [ 17 ] ) ) && this . map [ 16 ] && this . map [ 70 ] ) {
177173 e . preventDefault ( ) ; // prevent browser's default behaviour
178174 this . tidyCode ( ) ;
179175 }
@@ -339,7 +335,7 @@ class Editor extends React.Component {
339335 }
340336 }
341337
342- handleKey ( map , e ) { // update the state of each key pressed and released
338+ handleKey ( map , e ) { // update the 'keydown ' state of each key
343339 map [ e . keyCode ] = e . type === 'keydown' ;
344340 }
345341
You can’t perform that action at this time.
0 commit comments