EditContext: Immediately set isFocused field on focus call (#228325)

immediately handle the the field update
This commit is contained in:
Aiday Marlen Kyzy
2024-09-12 11:42:36 +02:00
committed by GitHub
parent d869359453
commit 0bd94f8a4e

View File

@@ -35,6 +35,9 @@ export class FocusTracker extends Disposable {
public focus(): void {
this._domNode.focus();
// fixes: https://github.com/microsoft/vscode/issues/228147
// Immediately call this method in order to directly set the field isFocused to true so the textInputFocus context key is evaluated correctly
this._handleFocusedChanged(true);
}
get isFocused(): boolean {