提交 e07eaeb9 编写于 作者: J jeanp413

Reset SearchView tree focus when there is a single result. Fixes #76475

上级 bdb28224
......@@ -738,6 +738,9 @@ export class SearchView extends ViewletPanel {
// Reveal the newly selected element
if (next) {
if (next === selected) {
this.tree.setFocus([]);
}
this.tree.setFocus([next], getSelectionKeyboardEvent(undefined, false));
this.tree.reveal(next);
}
......@@ -777,6 +780,9 @@ export class SearchView extends ViewletPanel {
// Reveal the newly selected element
if (prev) {
if (prev === selected) {
this.tree.setFocus([]);
}
this.tree.setFocus([prev], getSelectionKeyboardEvent(undefined, false));
this.tree.reveal(prev);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册