File tree Expand file tree Collapse file tree
src/vs/workbench/electron-browser Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -612,10 +612,18 @@ export class ElectronWindow extends Disposable {
612612 // are closed that the user wants to wait for. When this happens we delete
613613 // the wait marker file to signal to the outside that editing is done.
614614 const listener = this . editorService . onDidCloseEditor ( async event => {
615- const closedResource = toResource ( event . editor , { supportSideBySide : SideBySideEditor . MASTER } ) ;
615+ const detailsResource = toResource ( event . editor , { supportSideBySide : SideBySideEditor . DETAILS } ) ;
616+ const masterResource = toResource ( event . editor , { supportSideBySide : SideBySideEditor . MASTER } ) ;
617+
618+ // Remove from resources to wait for based on the
619+ // resources from editors that got closed
620+ resourcesToWaitFor = resourcesToWaitFor . filter ( resourceToWaitFor => {
621+ if ( isEqual ( resourceToWaitFor , masterResource ) || isEqual ( resourceToWaitFor , detailsResource ) ) {
622+ return false ; // remove - the closing editor matches this resource
623+ }
616624
617- // Remove from resources to wait for
618- resourcesToWaitFor = resourcesToWaitFor . filter ( resourceToWaitFor => ! isEqual ( closedResource , resourceToWaitFor ) ) ;
625+ return true ; // keep - not yet closed
626+ } ) ;
619627
620628 if ( resourcesToWaitFor . length === 0 ) {
621629 // If auto save is configured with the default delay (1s) it is possible
You can’t perform that action at this time.
0 commit comments