提交 46ba25e1 编写于 作者: B Benjamin Pasero

search editor - go back to canonical URI for now

上级 f48da22b
......@@ -229,7 +229,7 @@ export abstract class TitleControl extends Themable {
// Update contexts
this.contextKeyService.bufferChangeEvents(() => {
this.resourceContext.set(this.group.activeEditor ? withUndefinedAsNull(EditorResourceAccessor.getOriginalUri(this.group.activeEditor, { supportSideBySide: SideBySideEditor.PRIMARY })) : null);
this.resourceContext.set(withUndefinedAsNull(EditorResourceAccessor.getOriginalUri(this.group.activeEditor, { supportSideBySide: SideBySideEditor.PRIMARY })));
this.editorPinnedContext.set(this.group.activeEditor ? this.group.isPinned(this.group.activeEditor) : false);
this.editorStickyContext.set(this.group.activeEditor ? this.group.isSticky(this.group.activeEditor) : false);
});
......
......@@ -21,7 +21,7 @@ import { Registry } from 'vs/platform/registry/common/platform';
import { ITelemetryService } from 'vs/platform/telemetry/common/telemetry';
import { EditorDescriptor, Extensions as EditorExtensions, IEditorRegistry } from 'vs/workbench/browser/editor';
import { Extensions as WorkbenchExtensions, IWorkbenchContribution, IWorkbenchContributionsRegistry } from 'vs/workbench/common/contributions';
import { ActiveEditorContext, Extensions as EditorInputExtensions, IEditorInputFactory, IEditorInputFactoryRegistry, EditorResourceAccessor } from 'vs/workbench/common/editor';
import { ActiveEditorContext, Extensions as EditorInputExtensions, IEditorInputFactory, IEditorInputFactoryRegistry } from 'vs/workbench/common/editor';
import { IViewsService } from 'vs/workbench/common/views';
import { getSearchView } from 'vs/workbench/contrib/search/browser/searchActions';
import { searchRefreshIcon } from 'vs/workbench/contrib/search/browser/searchIcons';
......@@ -75,7 +75,7 @@ class SearchEditorContribution implements IWorkbenchContribution {
this.editorService.overrideOpenEditor({
open: (editor, options, group) => {
const resource = EditorResourceAccessor.getOriginalUri(editor);
const resource = editor.resource;
if (!resource) { return undefined; }
if (extname(resource) !== SEARCH_EDITOR_EXT) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册