chore(vscode): update to 1.53.2

These conflicts will be resolved in the following commits. We do it this way so
that PR review is possible.
This commit is contained in:
Joe Previte
2021-02-25 11:27:27 -07:00
1900 changed files with 83066 additions and 64589 deletions

View File

@@ -3,48 +3,97 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import { Action } from 'vs/base/common/actions';
import * as nls from 'vs/nls';
import { localize } from 'vs/nls';
import { INativeHostService } from 'vs/platform/native/electron-sandbox/native';
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
import { IEditorService } from 'vs/workbench/services/editor/common/editorService';
import { Action2, MenuId } from 'vs/platform/actions/common/actions';
import { CATEGORIES } from 'vs/workbench/common/actions';
import { ServicesAccessor } from 'vs/platform/instantiation/common/instantiation';
import { IWorkbenchEnvironmentService } from 'vs/workbench/services/environment/common/environmentService';
import { KeybindingWeight } from 'vs/platform/keybinding/common/keybindingsRegistry';
import { IsDevelopmentContext } from 'vs/platform/contextkey/common/contextkeys';
import { KeyCode, KeyMod } from 'vs/base/common/keyCodes';
export class ToggleDevToolsAction extends Action {
export class ToggleDevToolsAction extends Action2 {
static readonly ID = 'workbench.action.toggleDevTools';
static readonly LABEL = nls.localize('toggleDevTools', "Toggle Developer Tools");
constructor(
id: string,
label: string,
@INativeHostService private readonly nativeHostService: INativeHostService
) {
super(id, label);
constructor() {
super({
id: 'workbench.action.toggleDevTools',
title: { value: localize('toggleDevTools', "Toggle Developer Tools"), original: 'Toggle Developer Tools' },
category: CATEGORIES.Developer,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib + 50,
when: IsDevelopmentContext,
primary: KeyMod.CtrlCmd | KeyMod.Shift | KeyCode.KEY_I,
mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_I }
},
menu: {
id: MenuId.MenubarHelpMenu,
group: '5_tools',
order: 1
}
});
}
run(): Promise<void> {
return this.nativeHostService.toggleDevTools();
async run(accessor: ServicesAccessor): Promise<void> {
const nativeHostService = accessor.get(INativeHostService);
return nativeHostService.toggleDevTools();
}
}
export class ConfigureRuntimeArgumentsAction extends Action {
export class ConfigureRuntimeArgumentsAction extends Action2 {
static readonly ID = 'workbench.action.configureRuntimeArguments';
static readonly LABEL = nls.localize('configureRuntimeArguments', "Configure Runtime Arguments");
constructor(
id: string,
label: string,
@IEnvironmentService private readonly environmentService: IEnvironmentService,
@IEditorService private readonly editorService: IEditorService
) {
super(id, label);
constructor() {
super({
id: 'workbench.action.configureRuntimeArguments',
title: { value: localize('configureRuntimeArguments', "Configure Runtime Arguments"), original: 'Configure Runtime Arguments' },
category: CATEGORIES.Preferences,
f1: true
});
}
async run(): Promise<void> {
await this.editorService.openEditor({
resource: this.environmentService.argvResource,
async run(accessor: ServicesAccessor): Promise<void> {
const editorService = accessor.get(IEditorService);
const environmentService = accessor.get(IWorkbenchEnvironmentService);
await editorService.openEditor({
resource: environmentService.argvResource,
options: { pinned: true }
});
}
}
export class ToggleSharedProcessAction extends Action2 {
constructor() {
super({
id: 'workbench.action.toggleSharedProcess',
title: { value: localize('toggleSharedProcess', "Toggle Shared Process"), original: 'Toggle Shared Process' },
category: CATEGORIES.Developer,
f1: true
});
}
async run(accessor: ServicesAccessor): Promise<void> {
return accessor.get(INativeHostService).toggleSharedProcessWindow();
}
}
export class ReloadWindowWithExtensionsDisabledAction extends Action2 {
constructor() {
super({
id: 'workbench.action.reloadWindowWithExtensionsDisabled',
title: { value: localize('reloadWindowWithExtensionsDisabled', "Reload With Extensions Disabled"), original: 'Reload With Extensions Disabled' },
category: CATEGORIES.Developer,
f1: true
});
}
async run(accessor: ServicesAccessor): Promise<void> {
return accessor.get(INativeHostService).reload({ disableExtensions: true });
}
}