mirror of
https://github.com/arduino/arduino-ide.git
synced 2025-11-15 21:29:27 +00:00
redesigned the settings menu group.
Signed-off-by: Akos Kitta <kittaakos@typefox.io>
This commit is contained in:
@@ -1,11 +1,21 @@
|
||||
import { injectable } from 'inversify';
|
||||
import { isOSX } from '@theia/core/lib/common/os';
|
||||
import { MenuModelRegistry } from '@theia/core/lib/common/menu';
|
||||
import { KeybindingRegistry } from '@theia/core/lib/browser/keybinding';
|
||||
import { CommonCommands, CommonMenus } from '@theia/core/lib/browser';
|
||||
import { PreferencesContribution as TheiaPreferencesContribution } from '@theia/preferences/lib/browser/preference-contribution';
|
||||
import { CommonCommands } from '@theia/core/lib/browser';
|
||||
|
||||
@injectable()
|
||||
export class PreferencesContribution extends TheiaPreferencesContribution {
|
||||
|
||||
registerMenus(registry: MenuModelRegistry): void {
|
||||
super.registerMenus(registry);
|
||||
if (isOSX) {
|
||||
// The settings group: preferences, CLI config is not part of the `File` menu on macOS.
|
||||
registry.unregisterMenuAction(CommonCommands.OPEN_PREFERENCES.id, CommonMenus.FILE_SETTINGS_SUBMENU_OPEN);
|
||||
}
|
||||
}
|
||||
|
||||
registerKeybindings(registry: KeybindingRegistry): void {
|
||||
// https://github.com/eclipse-theia/theia/issues/8202
|
||||
registry.registerKeybinding({
|
||||
|
||||
Reference in New Issue
Block a user