Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix action category #142911

Merged
merged 1 commit into from Feb 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/vs/workbench/browser/actions/windowActions.ts
Expand Up @@ -285,7 +285,7 @@ class ToggleFullScreenAction extends Action2 {
mnemonicTitle: localize({ key: 'miToggleFullScreen', comment: ['&& denotes a mnemonic'] }, "&&Full Screen"),
original: 'Toggle Full Screen'
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib,
Expand Down Expand Up @@ -319,7 +319,7 @@ export class ReloadWindowAction extends Action2 {
super({
id: ReloadWindowAction.ID,
title: { value: localize('reloadWindow', "Reload Window"), original: 'Reload Window' },
category: CATEGORIES.Developer.value,
category: CATEGORIES.Developer,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib + 50,
Expand All @@ -346,7 +346,7 @@ class ShowAboutDialogAction extends Action2 {
mnemonicTitle: localize({ key: 'miAbout', comment: ['&& denotes a mnemonic'] }, "&&About"),
original: 'About'
},
category: CATEGORIES.Help.value,
category: CATEGORIES.Help,
f1: true,
menu: {
id: MenuId.MenubarHelpMenu,
Expand Down
Expand Up @@ -196,7 +196,7 @@ registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorAction, {
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorOrthogonalAction, { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KeyK, KeyMod.CtrlCmd | KeyCode.Backslash) }), 'View: Split Editor Orthogonal', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorLeftAction), 'View: Split Editor Left', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorRightAction), 'View: Split Editor Right', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorUpAction), 'Split Editor Up', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorUpAction), 'View: Split Editor Up', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(SplitEditorDownAction), 'View: Split Editor Down', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(JoinTwoGroupsAction), 'View: Join Editor Group with Next Group', CATEGORIES.View.value);
registry.registerWorkbenchAction(SyncActionDescriptor.from(JoinAllGroupsAction), 'View: Join All Editor Groups', CATEGORIES.View.value);
Expand Down
4 changes: 2 additions & 2 deletions src/vs/workbench/browser/parts/views/viewsService.ts
Expand Up @@ -351,7 +351,7 @@ export class ViewsService extends Disposable implements IViewsService {
return { value: localize('toggle view', "Toggle {0}", title), original: `Toggle ${title}` };
}
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
precondition: ContextKeyExpr.has(getEnabledViewContainerContextKey(viewContainer.id)),
keybinding: keybindings ? { ...keybindings, weight: KeybindingWeight.WorkbenchContrib } : undefined,
f1: true
Expand Down Expand Up @@ -417,7 +417,7 @@ export class ViewsService extends Disposable implements IViewsService {
return { value: localize('toggle view', "Toggle {0}", title), original: `Toggle ${title}` };
}
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
precondition: ContextKeyExpr.has(`${viewDescriptor.id}.active`),
keybinding: viewDescriptor.openCommandActionDescriptor!.keybindings ? { ...viewDescriptor.openCommandActionDescriptor!.keybindings, weight: KeybindingWeight.WorkbenchContrib } : undefined,
f1: true
Expand Down
Expand Up @@ -30,7 +30,7 @@ class StartDebugTextMate extends Action2 {
super({
id: 'editor.action.startDebugTextMate',
title: { value: nls.localize('startDebugTextMate', "Start Text Mate Syntax Grammar Logging"), original: 'Start Text Mate Syntax Grammar Logging' },
category: CATEGORIES.Developer.value,
category: CATEGORIES.Developer,
f1: true
});
}
Expand Down
Expand Up @@ -153,7 +153,7 @@ registerAction2(class extends Action2 {
super({
id: 'workbench.action.problems.focus',
title: { value: Messages.MARKERS_PANEL_SHOW_LABEL, original: 'Focus Problems (Errors, Warnings, Infos)' },
category: CATEGORIES.View.value,
category: CATEGORIES.View,
f1: true,
});
}
Expand Down
6 changes: 3 additions & 3 deletions src/vs/workbench/electron-sandbox/actions/windowActions.ts
Expand Up @@ -95,7 +95,7 @@ export class ZoomInAction extends BaseZoomAction {
mnemonicTitle: localize({ key: 'miZoomIn', comment: ['&& denotes a mnemonic'] }, "&&Zoom In"),
original: 'Zoom In'
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib,
Expand Down Expand Up @@ -125,7 +125,7 @@ export class ZoomOutAction extends BaseZoomAction {
mnemonicTitle: localize({ key: 'miZoomOut', comment: ['&& denotes a mnemonic'] }, "&&Zoom Out"),
original: 'Zoom Out'
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib,
Expand Down Expand Up @@ -159,7 +159,7 @@ export class ZoomResetAction extends BaseZoomAction {
mnemonicTitle: localize({ key: 'miZoomReset', comment: ['&& denotes a mnemonic'] }, "&&Reset Zoom"),
original: 'Reset Zoom'
},
category: CATEGORIES.View.value,
category: CATEGORIES.View,
f1: true,
keybinding: {
weight: KeybindingWeight.WorkbenchContrib,
Expand Down
Expand Up @@ -23,6 +23,7 @@ import { IProductService } from 'vs/platform/product/common/productService';
import { IWorkbenchIssueService } from 'vs/workbench/services/issue/common/issue';
import { IWorkbenchEnvironmentService } from 'vs/workbench/services/environment/common/environmentService';
import { areSameExtensions } from 'vs/platform/extensionManagement/common/extensionManagementUtil';
import { CATEGORIES } from 'vs/workbench/common/actions';

// --- bisect service

Expand Down Expand Up @@ -218,7 +219,7 @@ registerAction2(class extends Action2 {
super({
id: 'extension.bisect.start',
title: { value: localize('title.start', "Start Extension Bisect"), original: 'Start Extension Bisect' },
category: localize('help', "Help"),
category: CATEGORIES.Help,
f1: true,
precondition: ExtensionBisectUi.ctxIsBisectActive.negate(),
menu: {
Expand Down