mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-24 02:28:34 +01:00
wip
This commit is contained in:
@@ -161,6 +161,24 @@ export class MainThreadQuickOpen {
|
||||
}
|
||||
|
||||
$input(options?: InputBoxOptions): Thenable<string> {
|
||||
return this._quickOpenService.input(options);
|
||||
|
||||
let defaultItem = 'Insert text and press Enter or Escape';
|
||||
let userValue: string;
|
||||
|
||||
return new TPromise((resolve, reject) => {
|
||||
|
||||
this._quickOpenService.pick([defaultItem], {
|
||||
placeHolder: options.placeHolder,
|
||||
autoFocus: true,
|
||||
onDidType(value) {
|
||||
userValue = value;
|
||||
// console.log('TEXT')
|
||||
}
|
||||
}).then(item => {
|
||||
resolve(item && userValue);
|
||||
}, reject);
|
||||
});
|
||||
|
||||
// return this._quickOpenService.input(options);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user