mirror of
https://github.com/Microsoft/vscode
synced 2024-09-13 13:46:13 +00:00
tabindex calls blur() to early
This commit is contained in:
parent
f14bc31be8
commit
9d161efa98
|
@ -1793,8 +1793,6 @@ class StickyScrollFocus<T, TFilterData, TRef> extends Disposable {
|
|||
this.elements = elements;
|
||||
this.state = state;
|
||||
|
||||
this.container.tabIndex = state ? 0 : -1;
|
||||
|
||||
if (state) {
|
||||
const newFocusedIndex = clamp(previousIndex, 0, state.count - 1);
|
||||
this.setFocus(newFocusedIndex);
|
||||
|
@ -1803,6 +1801,9 @@ class StickyScrollFocus<T, TFilterData, TRef> extends Disposable {
|
|||
this.view.domFocus();
|
||||
}
|
||||
}
|
||||
|
||||
// must come last as it calls blur()
|
||||
this.container.tabIndex = state ? 0 : -1;
|
||||
}
|
||||
|
||||
private setFocusedElement(stickyIndex: number): void {
|
||||
|
|
Loading…
Reference in a new issue