From fe76fb26e20fa3b547bcd0d207c6e89c37b971d0 Mon Sep 17 00:00:00 2001 From: Christof Marti Date: Wed, 21 Mar 2018 11:18:19 +0100 Subject: [PATCH] Cmd+Space hint (#45589) --- src/vs/workbench/browser/parts/quickinput/quickInput.ts | 5 +++-- src/vs/workbench/browser/parts/quickinput/quickInputBox.ts | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/vs/workbench/browser/parts/quickinput/quickInput.ts b/src/vs/workbench/browser/parts/quickinput/quickInput.ts index 48f3e38249294..d157108f0744b 100644 --- a/src/vs/workbench/browser/parts/quickinput/quickInput.ts +++ b/src/vs/workbench/browser/parts/quickinput/quickInput.ts @@ -34,7 +34,7 @@ export class QuickInputService extends Component implements IQuickInputService { private static readonly ID = 'workbench.component.quickinput'; private static readonly MAX_WIDTH = 600; // Max total width of quick open widget - // private static readonly MAX_ITEMS_HEIGHT = 20 * 22; // Max height of item list below input field + // private static readonly MAX_ITEMS_HEIGHT = 20 * 22; // TODO Max height of item list below input field private layoutDimensions: Dimension; private container: HTMLElement; @@ -145,7 +145,8 @@ export class QuickInputService extends Component implements IQuickInputService { } this.inputBox.setValue(''); - this.inputBox.setPlaceholder(options.placeHolder || ''); + // TODO: Localize shortcut. + this.inputBox.setPlaceholder(options.placeHolder ? localize('quickInput.ctrlSpaceToSelectWithPlaceholder', "{1} ({0} to toggle)", 'Cmd+Space', options.placeHolder) : localize('quickInput.ctrlSpaceToSelect', "{0} to toggle", 'Cmd+Space')); // TODO: Progress indication. this.checkboxList.setElements(await picks); diff --git a/src/vs/workbench/browser/parts/quickinput/quickInputBox.ts b/src/vs/workbench/browser/parts/quickinput/quickInputBox.ts index 2c780a001a21b..af3f90784a817 100644 --- a/src/vs/workbench/browser/parts/quickinput/quickInputBox.ts +++ b/src/vs/workbench/browser/parts/quickinput/quickInputBox.ts @@ -16,7 +16,7 @@ import { StandardKeyboardEvent } from 'vs/base/browser/keyboardEvent'; const $ = dom.$; -const DEFAULT_INPUT_ARIA_LABEL = localize('quickInputBoxAriaLabel', "Type to narrow down results."); +const DEFAULT_INPUT_ARIA_LABEL = localize('quickInputBox.ariaLabel', "Type to narrow down results."); export class QuickInputBox {