提交 401c633b 编写于 作者: J Jackson Kearl

[Search on Type] Dont trigger search on initalizatioon. Fixes #86129.

上级 02a1ddcf
......@@ -149,12 +149,6 @@ export class PatternInputWidget extends Widget {
this._register(attachInputBoxStyler(this.inputBox, this.themeService));
this.inputFocusTracker = dom.trackFocus(this.inputBox.inputElement);
this.onkeyup(this.inputBox.inputElement, (keyboardEvent) => this.onInputKeyUp(keyboardEvent));
this._register(this.inputBox.onDidChange(() => {
if (this.searchConfig.searchOnType) {
this._onCancel.fire();
this.searchOnTypeDelayer.trigger(() => this._onSubmit.fire(true), this.searchConfig.searchOnTypeDebouncePeriod);
}
}));
const controls = document.createElement('div');
controls.className = 'controls';
......@@ -176,6 +170,10 @@ export class PatternInputWidget extends Widget {
this._onCancel.fire();
return;
default:
if (this.searchConfig.searchOnType) {
this._onCancel.fire();
this.searchOnTypeDelayer.trigger(() => this._onSubmit.fire(true), this.searchConfig.searchOnTypeDebouncePeriod);
}
return;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册