@@ -454,7 +454,7 @@ export class EditorService extends Disposable implements EditorServiceImpl {
454454
455455 //#region createInput()
456456
457- createInput ( input : IEditorInputWithOptions | IEditorInput | IResourceEditor , options ?: { forceFileInput : boolean } ) : EditorInput {
457+ createInput ( input : IEditorInputWithOptions | IEditorInput | IResourceEditor ) : EditorInput {
458458
459459 // Typed Editor Input Support (EditorInput)
460460 if ( input instanceof EditorInput ) {
@@ -470,8 +470,8 @@ export class EditorService extends Disposable implements EditorServiceImpl {
470470 // Side by Side Support
471471 const resourceSideBySideInput = < IResourceSideBySideInput > input ;
472472 if ( resourceSideBySideInput . masterResource && resourceSideBySideInput . detailResource ) {
473- const masterInput = this . createInput ( { resource : resourceSideBySideInput . masterResource } , options ) ;
474- const detailInput = this . createInput ( { resource : resourceSideBySideInput . detailResource } , options ) ;
473+ const masterInput = this . createInput ( { resource : resourceSideBySideInput . masterResource } ) ;
474+ const detailInput = this . createInput ( { resource : resourceSideBySideInput . detailResource } ) ;
475475
476476 return new SideBySideEditorInput (
477477 resourceSideBySideInput . label || masterInput . getName ( ) ,
@@ -484,8 +484,8 @@ export class EditorService extends Disposable implements EditorServiceImpl {
484484 // Diff Editor Support
485485 const resourceDiffInput = < IResourceDiffInput > input ;
486486 if ( resourceDiffInput . leftResource && resourceDiffInput . rightResource ) {
487- const leftInput = this . createInput ( { resource : resourceDiffInput . leftResource } , options ) ;
488- const rightInput = this . createInput ( { resource : resourceDiffInput . rightResource } , options ) ;
487+ const leftInput = this . createInput ( { resource : resourceDiffInput . leftResource } ) ;
488+ const rightInput = this . createInput ( { resource : resourceDiffInput . rightResource } ) ;
489489 const label = resourceDiffInput . label || localize ( 'compareLabels' , "{0} ↔ {1}" , this . toDiffLabel ( leftInput ) , this . toDiffLabel ( rightInput ) ) ;
490490
491491 return new DiffEditorInput ( label , resourceDiffInput . description , leftInput , rightInput ) ;
@@ -510,13 +510,13 @@ export class EditorService extends Disposable implements EditorServiceImpl {
510510 label = basename ( resourceInput . resource . fsPath ) ; // derive the label from the path (but not for data URIs)
511511 }
512512
513- return this . createOrGet ( resourceInput . resource , this . instantiationService , label , resourceInput . description , resourceInput . encoding , options && options . forceFileInput ) as EditorInput ;
513+ return this . createOrGet ( resourceInput . resource , this . instantiationService , label , resourceInput . description , resourceInput . encoding , resourceInput . isFile ) as EditorInput ;
514514 }
515515
516516 return null ;
517517 }
518518
519- private createOrGet ( resource : URI , instantiationService : IInstantiationService , label : string , description : string , encoding ?: string , forceFileInput ?: boolean ) : ICachedEditorInput {
519+ private createOrGet ( resource : URI , instantiationService : IInstantiationService , label : string , description : string , encoding ?: string , isFile ?: boolean ) : ICachedEditorInput {
520520 if ( EditorService . CACHE . has ( resource ) ) {
521521 const input = EditorService . CACHE . get ( resource ) ;
522522 if ( input instanceof ResourceEditorInput ) {
@@ -532,7 +532,7 @@ export class EditorService extends Disposable implements EditorServiceImpl {
532532 let input : ICachedEditorInput ;
533533
534534 // File
535- if ( this . fileService . canHandleResource ( resource ) || forceFileInput /* fix for https://github.com/Microsoft/vscode/issues/48275 */ ) {
535+ if ( isFile /* fix for https://github.com/Microsoft/vscode/issues/48275 */ || this . fileService . canHandleResource ( resource ) ) {
536536 input = this . fileInputFactory . createFileInput ( resource , encoding , instantiationService ) ;
537537 }
538538
0 commit comments