File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -615,7 +615,10 @@ Visibility.change(function (e, state) {
615615 }
616616 } else {
617617 if ( wasFocus ) {
618- editor . focus ( ) ;
618+ if ( ! visibleXS ) {
619+ editor . focus ( ) ;
620+ editor . refresh ( ) ;
621+ }
619622 wasFocus = false ;
620623 }
621624 setHaveUnreadChanges ( false ) ;
@@ -915,10 +918,7 @@ function changeMode(type) {
915918 ui . area . view . show ( ) ;
916919 break ;
917920 }
918- if ( currentMode != modeType . view && visibleLG ) {
919- //editor.focus();
920- //editor.refresh();
921- } else {
921+ if ( currentMode == modeType . view ) {
922922 editor . getInputField ( ) . blur ( ) ;
923923 }
924924 if ( currentMode == modeType . edit || currentMode == modeType . both ) {
@@ -1536,7 +1536,7 @@ socket.on('refresh', function (data) {
15361536 currentMode = modeType . both ;
15371537 }
15381538 changeMode ( currentMode ) ;
1539- if ( nocontent ) {
1539+ if ( nocontent && ! visibleXS ) {
15401540 editor . focus ( ) ;
15411541 editor . refresh ( ) ;
15421542 }
You can’t perform that action at this time.
0 commit comments