UNPKG

sussudio

Version:

An unofficial VS Code Internal API

73 lines (72 loc) 3.63 kB
/*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ import { IConfigurationService } from "../../configuration/common/configuration.mjs"; import { IEnvironmentMainService } from "../../environment/electron-main/environmentMainService.mjs"; import { ILifecycleMainService } from "../../lifecycle/electron-main/lifecycleMainService.mjs"; import { ILogService } from "../../log/common/log.mjs"; import { IMenubarData } from "../common/menubar.mjs"; import { INativeHostMainService } from "../../native/electron-main/nativeHostMainService.mjs"; import { IProductService } from "../../product/common/productService.mjs"; import { IStateMainService } from "../../state/electron-main/state.mjs"; import { ITelemetryService } from "../../telemetry/common/telemetry.mjs"; import { IUpdateService } from "../../update/common/update.mjs"; import { IWindowsMainService } from "../../windows/electron-main/windows.mjs"; import { IWorkspacesHistoryMainService } from "../../workspaces/electron-main/workspacesHistoryMainService.mjs"; export declare class Menubar { private readonly updateService; private readonly configurationService; private readonly windowsMainService; private readonly environmentMainService; private readonly telemetryService; private readonly workspacesHistoryMainService; private readonly stateMainService; private readonly lifecycleMainService; private readonly logService; private readonly nativeHostMainService; private readonly productService; private static readonly lastKnownMenubarStorageKey; private willShutdown; private appMenuInstalled; private closedLastWindow; private noActiveWindow; private menuUpdater; private menuGC; private oldMenus; private menubarMenus; private keybindings; private readonly fallbackMenuHandlers; constructor(updateService: IUpdateService, configurationService: IConfigurationService, windowsMainService: IWindowsMainService, environmentMainService: IEnvironmentMainService, telemetryService: ITelemetryService, workspacesHistoryMainService: IWorkspacesHistoryMainService, stateMainService: IStateMainService, lifecycleMainService: ILifecycleMainService, logService: ILogService, nativeHostMainService: INativeHostMainService, productService: IProductService); private restoreCachedMenubarData; private addFallbackHandlers; private registerListeners; private get currentEnableMenuBarMnemonics(); private get currentEnableNativeTabs(); updateMenu(menubarData: IMenubarData, windowId: number): void; private scheduleUpdateMenu; private doUpdateMenu; private onDidChangeWindowsCount; private onDidChangeWindowFocus; private install; private setMacApplicationMenu; private confirmBeforeQuit; private shouldDrawMenu; private setMenu; private setMenuById; private insertCheckForUpdatesItems; private createOpenRecentMenuItem; private isOptionClick; private isKeyboardEvent; private createRoleMenuItem; private setMacWindowMenu; private getUpdateMenuItems; private createMenuItem; private makeContextAwareClickHandler; private runActionInRenderer; private withKeybinding; private likeAction; private openUrl; private reportMenuActionTelemetry; private mnemonicLabel; }