IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
|
|
|
1115 | 1115 | |
1116 | 1116 | focus : function() |
1117 | 1117 | { |
1118 | | var win = editor.window; |
| 1118 | // We must use the body element which is the |
| 1119 | // editable element itself to apply focus, to avoid |
| 1120 | // any unexpected page scroll. (#) |
| 1121 | var body = editor.document.getBody(); |
1119 | 1122 | |
1120 | 1123 | if ( isLoadingData ) |
1121 | 1124 | isPendingFocus = true; |
1122 | | else if ( win ) |
| 1125 | else if ( body ) |
1123 | 1126 | { |
1124 | 1127 | var sel = editor.getSelection(), |
1125 | 1128 | ieSel = sel && sel.getNative(); |
… |
… |
|
1131 | 1134 | return; |
1132 | 1135 | |
1133 | 1136 | // AIR needs a while to focus when moving from a link. |
1134 | | CKEDITOR.env.air ? setTimeout( function () { win.focus(); }, 0 ) : win.focus(); |
| 1137 | CKEDITOR.env.air ? setTimeout( function () { body.focus(); }, 0 ) : body.focus(); |
1135 | 1138 | editor.selectionChange(); |
1136 | 1139 | } |
1137 | 1140 | } |