提交 39b5a2fd 编写于 作者: B Benjamin Pasero

fix activation issue with ShowEditorsInGroupAction

上级 46b2f420
......@@ -870,9 +870,22 @@ export class ShowEditorsInGroupAction extends QuickOpenAction {
public static ID = 'workbench.action.showEditorsInGroup';
public static LABEL = nls.localize('showEditorsInGroup', "Show Editors in Group");
constructor(actionId: string, actionLabel: string, @IQuickOpenService quickOpenService: IQuickOpenService) {
constructor(
actionId: string,
actionLabel: string,
@IQuickOpenService quickOpenService: IQuickOpenService,
@IWorkbenchEditorService private editorService: IWorkbenchEditorService
) {
super(actionId, actionLabel, NAVIGATE_IN_GROUP_PREFIX, quickOpenService);
}
public run(editorIdentifier: IEditorIdentifier): TPromise<any> {
if (editorIdentifier) {
this.editorService.activateGroup(this.editorService.getStacksModel().positionOfGroup(editorIdentifier.group)); // workaround for not having a group specific quick open for opened editors
}
return super.run(editorIdentifier);
}
}
export const NAVIGATE_ALL_EDITORS_GROUP_PREFIX = '~';
......
......@@ -396,7 +396,7 @@ export class QuickOpenAction extends Action {
this.enabled = !!this.quickOpenService;
}
public run(): TPromise<any> {
public run(context: any): TPromise<any> {
// Show with prefix
this.quickOpenService.show(this.prefix);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册