mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-21 23:58:07 +02:00
Ensure that the PDFHistory._maxUid
property is correctly updated when initializing/navigating the history
This is a follow-up to commit e772124339
, in PR 8994, to cover a couple of cases missed there.
This commit is contained in:
parent
5a52ee0a79
commit
448a7a27cb
1 changed files with 6 additions and 0 deletions
|
@ -133,6 +133,9 @@ class PDFHistory {
|
|||
let destination = state.destination;
|
||||
this._updateInternalState(destination, state.uid,
|
||||
/* removeTemporary = */ true);
|
||||
if (this._uid > this._maxUid) {
|
||||
this._maxUid = this._uid;
|
||||
}
|
||||
|
||||
if (destination.rotation !== undefined) {
|
||||
this.initialRotation = destination.rotation;
|
||||
|
@ -510,6 +513,9 @@ class PDFHistory {
|
|||
let destination = state.destination;
|
||||
this._updateInternalState(destination, state.uid,
|
||||
/* removeTemporary = */ true);
|
||||
if (this._uid > this._maxUid) {
|
||||
this._maxUid = this._uid;
|
||||
}
|
||||
|
||||
if (isValidRotation(destination.rotation)) {
|
||||
this.linkService.rotation = destination.rotation;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue