Merge pull request #19226 from Snuffleupagus/pr-19216-followup
Disable touch-zooming, in the viewer, if `AbortSignal.any` is unsupported (PR 19216 follow-up)
This commit is contained in:
commit
8985d80aef
21
web/app.js
21
web/app.js
@ -2045,14 +2045,19 @@ const PDFViewerApplication = {
|
|||||||
_windowAbortController: { signal },
|
_windowAbortController: { signal },
|
||||||
} = this;
|
} = this;
|
||||||
|
|
||||||
this._touchManager = new TouchManager({
|
if (
|
||||||
container: window,
|
(typeof PDFJSDev !== "undefined" && PDFJSDev.test("MOZCENTRAL")) ||
|
||||||
isPinchingDisabled: () => this.pdfViewer.isInPresentationMode,
|
typeof AbortSignal.any === "function"
|
||||||
isPinchingStopped: () => this.overlayManager?.active,
|
) {
|
||||||
onPinching: this.touchPinchCallback.bind(this),
|
this._touchManager = new TouchManager({
|
||||||
onPinchEnd: this.touchPinchEndCallback.bind(this),
|
container: window,
|
||||||
signal,
|
isPinchingDisabled: () => pdfViewer.isInPresentationMode,
|
||||||
});
|
isPinchingStopped: () => this.overlayManager?.active,
|
||||||
|
onPinching: this.touchPinchCallback.bind(this),
|
||||||
|
onPinchEnd: this.touchPinchEndCallback.bind(this),
|
||||||
|
signal,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function addWindowResolutionChange(evt = null) {
|
function addWindowResolutionChange(evt = null) {
|
||||||
if (evt) {
|
if (evt) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user