[Pkg-javascript-commits] [pdf.js] 05/207: Disables worker if XHR does not support arraybuffer

David Prévot taffit at moszumanska.debian.org
Mon Jul 28 15:36:23 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit f9befa189b0cbb73a7132120d42406cd7a4c0219
Author: Yury Delendik <ydelendik at mozilla.com>
Date:   Thu May 29 20:34:20 2014 -0500

    Disables worker if XHR does not support arraybuffer
---
 web/compatibility.js | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/web/compatibility.js b/web/compatibility.js
index 8b687b6..98d2dcb 100644
--- a/web/compatibility.js
+++ b/web/compatibility.js
@@ -163,6 +163,10 @@ if (typeof PDFJS === 'undefined') {
   if ('responseType' in xhr) {
     return;
   }
+
+  // The worker will be using XHR, so we can save time and disable worker.
+  PDFJS.disableWorker = true;
+
   // Support: IE9
   if (typeof VBArray !== 'undefined') {
     Object.defineProperty(xhrPrototype, 'response', {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list