提交 53aa2d6a 编写于 作者: S SteVen Batten 提交者: Martin Aeschlimann

fixes #55248

上级 13f6721b
......@@ -67,7 +67,7 @@ export class Menubar {
});
// // Listen to some events from window service to update menu
// this.historyMainService.onRecentlyOpenedChange(() => this.updateMenu());
this.historyMainService.onRecentlyOpenedChange(() => this.scheduleUpdateMenu());
this.windowsMainService.onWindowsCountChanged(e => this.onWindowsCountChanged(e));
// this.windowsMainService.onActiveWindowChanged(() => this.updateWorkspaceMenuItems());
// this.windowsMainService.onWindowReady(() => this.updateWorkspaceMenuItems());
......@@ -391,11 +391,16 @@ export class Menubar {
const openWorkspace = new MenuItem(this.likeAction('workbench.action.openWorkspace', { label: this.mnemonicLabel(nls.localize({ key: 'miOpenWorkspace', comment: ['&& denotes a mnemonic'] }, "Open Wor&&kspace...")), click: (menuItem, win, event) => this.windowsMainService.pickWorkspaceAndOpen({ forceNewWindow: this.isOptionClick(event), telemetryExtraData: { from: telemetryFrom } }) }));
const openRecentMenu = new Menu();
this.setFallbackMenuById(openRecentMenu, 'Recent');
const openRecent = new MenuItem({ label: this.mnemonicLabel(nls.localize({ key: 'miOpenRecent', comment: ['&& denotes a mnemonic'] }, "Open &&Recent")), submenu: openRecentMenu });
menu.append(newFile);
menu.append(newWindow);
menu.append(__separator__());
menu.append(open);
menu.append(openWorkspace);
menu.append(openRecent);
break;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册