Merge pull request #15455 from Snuffleupagus/issue-15453
Don't update the Scroll/Spread-mode in the ViewHistory while PresentationMode is active (issue 15453)
This commit is contained in:
commit
67160f4cae
10
web/app.js
10
web/app.js
@ -2469,7 +2469,10 @@ function webViewerUpdateViewarea({ location }) {
|
||||
}
|
||||
|
||||
function webViewerScrollModeChanged(evt) {
|
||||
if (PDFViewerApplication.isInitialViewSet) {
|
||||
if (
|
||||
PDFViewerApplication.isInitialViewSet &&
|
||||
!PDFViewerApplication.pdfViewer.isInPresentationMode
|
||||
) {
|
||||
// Only update the storage when the document has been loaded *and* rendered.
|
||||
PDFViewerApplication.store?.set("scrollMode", evt.mode).catch(() => {
|
||||
// Unable to write to storage.
|
||||
@ -2478,7 +2481,10 @@ function webViewerScrollModeChanged(evt) {
|
||||
}
|
||||
|
||||
function webViewerSpreadModeChanged(evt) {
|
||||
if (PDFViewerApplication.isInitialViewSet) {
|
||||
if (
|
||||
PDFViewerApplication.isInitialViewSet &&
|
||||
!PDFViewerApplication.pdfViewer.isInPresentationMode
|
||||
) {
|
||||
// Only update the storage when the document has been loaded *and* rendered.
|
||||
PDFViewerApplication.store?.set("spreadMode", evt.mode).catch(() => {
|
||||
// Unable to write to storage.
|
||||
|
Loading…
Reference in New Issue
Block a user