Skip to content

Commit

Permalink
Merge pull request #17220 from Snuffleupagus/pr-17176-followup
Browse files Browse the repository at this point in the history
Also pause translation when expanding the current outline-item (PR 17176 follow-up)
  • Loading branch information
timvandermeij authored Nov 4, 2023
2 parents 0d574f6 + bf7e812 commit 87c83ab
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions web/base_tree_viewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ class BaseTreeViewer {
if (!treeItem) {
return;
}
// Pause translation when expanding the treeItem.
this._l10n.pause();
// Ensure that the treeItem is *fully* expanded, such that it will first of
// all be visible and secondly that scrolling it into view works correctly.
let currentNode = treeItem.parentNode;
Expand All @@ -171,6 +173,8 @@ class BaseTreeViewer {
}
currentNode = currentNode.parentNode;
}
this._l10n.resume();

this._updateCurrentTreeItem(treeItem);

this.container.scrollTo(
Expand Down

0 comments on commit 87c83ab

Please sign in to comment.