mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-26 03:29:00 +01:00
check for input box options, fixes #7013
This commit is contained in:
@@ -232,7 +232,9 @@ export class ExtHostAPIImplementation {
|
||||
showQuickPick: (items: any, options: vscode.QuickPickOptions) => {
|
||||
return extHostQuickOpen.show(items, options);
|
||||
},
|
||||
showInputBox: extHostQuickOpen.input.bind(extHostQuickOpen),
|
||||
showInputBox(options?: vscode.InputBoxOptions) {
|
||||
return extHostQuickOpen.input(options);
|
||||
},
|
||||
|
||||
createStatusBarItem(position?: vscode.StatusBarAlignment, priority?: number): vscode.StatusBarItem {
|
||||
return extHostStatusBar.createStatusBarEntry(<number>position, priority);
|
||||
|
||||
@@ -101,8 +101,8 @@ export class ExtHostQuickOpen {
|
||||
// ---- input
|
||||
|
||||
input(options?: InputBoxOptions): Thenable<string> {
|
||||
this._validateInput = options.validateInput;
|
||||
return this._proxy.$input(options, typeof options.validateInput === 'function');
|
||||
this._validateInput = options && options.validateInput;
|
||||
return this._proxy.$input(options, options && typeof options.validateInput === 'function');
|
||||
}
|
||||
|
||||
$validateInput(input: string): TPromise<string> {
|
||||
|
||||
Reference in New Issue
Block a user