提交 fd5ecc5d 编写于 作者: S SteVen Batten

removing dummy commands from menubar

上级 069a812b
......@@ -4,12 +4,9 @@
*--------------------------------------------------------------------------------------------*/
import * as nls from 'vs/nls';
import * as menubarCommands from 'vs/workbench/browser/parts/menubar/menubarCommands';
import { MenuRegistry, MenuId } from 'vs/platform/actions/common/actions';
import { isMacintosh } from 'vs/base/common/platform';
// TODO: Add submenu support to remove layout, preferences, and recent top level
menubarCommands.setup();
recentMenuRegistration();
fileMenuRegistration();
editMenuRegistration();
......
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { KeybindingsRegistry } from 'vs/platform/keybinding/common/keybindingsRegistry';
import { KeyMod, KeyCode } from 'vs/base/common/keyCodes';
import URI from 'vs/base/common/uri';
export const FILE_MENU_FAKE_OPEN_FILE_COMMAND_ID = 'workbench.action.fakeOpenFile';
export function setup(): void {
registerMenubarCommands();
}
function registerMenubarCommands() {
KeybindingsRegistry.registerCommandAndKeybindingRule({
id: FILE_MENU_FAKE_OPEN_FILE_COMMAND_ID,
weight: KeybindingsRegistry.WEIGHT.workbenchContrib(),
when: void 0,
primary: KeyMod.CtrlCmd | KeyCode.F6,
win: { primary: KeyMod.CtrlCmd | KeyCode.F6 },
handler: (accessor, resource: URI | object) => {
alert('fake open successful');
console.log('fake open triggered');
}
});
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册