提交 8526234c 编写于 作者: B Benjamin Pasero

💄

上级 32dd1b76
......@@ -22,7 +22,6 @@ import { RefreshViewExplorerAction, NewFolderAction, NewFileAction } from 'vs/wo
import { FileDragAndDrop, FileFilter, FileSorter, FileController, FileRenderer, FileDataSource, FileViewletState, FileAccessibilityProvider } from 'vs/workbench/parts/files/browser/views/explorerViewer';
import { toResource } from 'vs/workbench/common/editor';
import { DiffEditorInput } from 'vs/workbench/common/editor/diffEditorInput';
import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput';
import { IEditorGroupService } from 'vs/workbench/services/group/common/groupService';
import * as DOM from 'vs/base/browser/dom';
import { CollapseAction, CollapsibleViewletView } from 'vs/workbench/browser/viewlet';
......@@ -204,7 +203,7 @@ export class ExplorerView extends CollapsibleViewletView {
// Handle closed or untitled file (convince explorer to not reopen any file when getting visible)
const activeInput = this.editorService.getActiveEditorInput();
if (activeInput instanceof UntitledEditorInput || !activeInput) {
if (!activeInput || toResource(activeInput, { supportSideBySide: true, filter: 'untitled' })) {
this.settings[ExplorerView.MEMENTO_LAST_ACTIVE_FILE_RESOURCE] = void 0;
clearFocus = true;
}
......
......@@ -8,7 +8,6 @@
import URI from 'vs/base/common/uri';
import paths = require('vs/base/common/paths');
import { IFileStat, isEqual, isParent, isEqualOrParent } from 'vs/platform/files/common/files';
import { UntitledEditorInput } from 'vs/workbench/common/editor/untitledEditorInput';
import { IEditorInput } from 'vs/platform/editor/common/editor';
import { IEditorGroup, toResource } from 'vs/workbench/common/editor';
import { ResourceMap } from 'vs/base/common/map';
......@@ -361,7 +360,7 @@ export class OpenEditor {
}
public isUntitled(): boolean {
return this.editor instanceof UntitledEditorInput;
return !!toResource(this.editor, { supportSideBySide: true, filter: 'untitled' });
}
public isDirty(): boolean {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册