Merge pull request #10201 from Snuffleupagus/find-less-updatePage
Reduce the number of redundant `updatetextlayermatches` events dispatched when calculating matches in `PDFFindController`
This commit is contained in:
commit
bb5f261c58
@ -345,7 +345,11 @@ class PDFFindController {
|
||||
this._calculateWordMatch(query, pageIndex, pageContent, entireWord);
|
||||
}
|
||||
|
||||
this._updatePage(pageIndex);
|
||||
// When `highlightAll` is set, ensure that the matches on previously
|
||||
// rendered (and still active) pages are correctly highlighted.
|
||||
if (this._state.highlightAll) {
|
||||
this._updatePage(pageIndex);
|
||||
}
|
||||
if (this._resumePageIdx === pageIndex) {
|
||||
this._resumePageIdx = null;
|
||||
this._nextPageMatch();
|
||||
|
Loading…
x
Reference in New Issue
Block a user