File tree 1 file changed +1
-9
lines changed
1 file changed +1
-9
lines changed Original file line number Diff line number Diff line change @@ -161,7 +161,6 @@ export class EditorController extends Controller implements IEditorController {
161
161
162
162
public onSelectTab = ( tabId : string , groupId : number ) => {
163
163
this . editorService . setActive ( groupId , tabId ) ;
164
- this . updateCurrentValue ( ) ;
165
164
this . emit ( EditorEvent . OnSelectTab , tabId , groupId ) ;
166
165
} ;
167
166
@@ -282,15 +281,8 @@ export class EditorController extends Controller implements IEditorController {
282
281
283
282
private initializeFile ( path : string , value : string , language : string ) {
284
283
let model = monacoEditor . getModel ( Uri . parse ( path ) ) ;
285
- const { current } = this . editorService . getState ( ) ;
286
284
if ( model ) {
287
- current ?. editorInstance ?. executeEdits ( 'update-value' , [
288
- {
289
- range : model . getFullModelRange ( ) ,
290
- text : value ,
291
- forceMoveMarkers : true ,
292
- } ,
293
- ] ) ;
285
+ model . setValue ( value ) ;
294
286
} else {
295
287
model = monacoEditor . createModel ( value , language , Uri . parse ( path ) ) ;
296
288
}
You can’t perform that action at this time.
0 commit comments