File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -373,7 +373,7 @@ var CodeMirror = (function() {
373373 focused = true ;
374374 if ( wrapper . className . search ( / \b C o d e M i r r o r - f o c u s e d \b / ) == - 1 )
375375 wrapper . className += " CodeMirror-focused" ;
376- prepareInput ( ) ;
376+ if ( ! leaveInputAlone ) prepareInput ( ) ;
377377 }
378378 slowPoll ( ) ;
379379 restartBlink ( ) ;
@@ -1172,10 +1172,10 @@ var CodeMirror = (function() {
11721172 input . style . cssText = "position: fixed; width: 30px; height: 30px; top: " + ( e . pageY ( ) - 1 ) +
11731173 "px; left: " + ( e . pageX ( ) - 1 ) + "px; z-index: 1000; background: white; " +
11741174 "border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);" ;
1175+ leaveInputAlone = true ;
11751176 var val = input . value = getSelection ( ) ;
11761177 focusInput ( ) ;
11771178 setSelRange ( input , 0 , input . value . length ) ;
1178- leaveInputAlone = true ;
11791179 function rehide ( ) {
11801180 var newVal = splitLines ( input . value ) . join ( "\n" ) ;
11811181 if ( newVal != val ) operation ( replaceSelection ) ( newVal , "end" ) ;
You can’t perform that action at this time.
0 commit comments