parent
693677c8a2
commit
e94e8ed399
1 changed files with 8 additions and 3 deletions
|
@ -215,9 +215,14 @@ export class TerminalViewPane extends ViewPane {
|
|||
|
||||
const defaultProfileName = this._terminalProfileResolverService.defaultProfileName;
|
||||
for (const p of profiles) {
|
||||
const suffix = p.profileName === defaultProfileName ? nls.localize('defaultTerminalSuffix', " (Default)") : '';
|
||||
dropdownActions.push(new MenuItemAction({ id: TerminalCommandId.NewWithProfile, title: p.profileName + suffix, category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
submenuActions.push(new MenuItemAction({ id: TerminalCommandId.Split, title: p.profileName + suffix, category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
const isDefault = p.profileName === defaultProfileName;
|
||||
if (isDefault) {
|
||||
dropdownActions.unshift(new MenuItemAction({ id: TerminalCommandId.NewWithProfile, title: nls.localize('defaultTerminalProfile', "{0} (Default)", p.profileName), category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
submenuActions.unshift(new MenuItemAction({ id: TerminalCommandId.Split, title: nls.localize('defaultTerminalProfile', "{0} (Default)", p.profileName), category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
} else {
|
||||
dropdownActions.push(new MenuItemAction({ id: TerminalCommandId.NewWithProfile, title: p.profileName, category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
submenuActions.push(new MenuItemAction({ id: TerminalCommandId.Split, title: p.profileName, category: TerminalTabContextMenuGroup.Profile }, undefined, { arg: p, shouldForwardArgs: true }, this._contextKeyService, this._commandService));
|
||||
}
|
||||
}
|
||||
|
||||
for (const contributed of this._terminalContributionService.terminalTypes) {
|
||||
|
|
Loading…
Reference in a new issue