diff --git a/bower.json b/bower.json index 162dab65f..af0740b6b 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "pdfjs-dist", - "version": "1.0.353", + "version": "1.0.355", "keywords": [ "Mozilla", "pdf", diff --git a/build/pdf.combined.js b/build/pdf.combined.js index cacca859f..65c42b0e9 100644 --- a/build/pdf.combined.js +++ b/build/pdf.combined.js @@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') { (typeof window !== 'undefined' ? window : this).PDFJS = {}; } -PDFJS.version = '1.0.353'; -PDFJS.build = '480e093'; +PDFJS.version = '1.0.355'; +PDFJS.build = '2efbdfe'; (function pdfjsWrapper() { // Use strict in our context only - users might not want it @@ -2481,6 +2481,14 @@ PDFJS.useOnlyCssZoom = (PDFJS.useOnlyCssZoom === undefined ? PDFJS.verbosity = (PDFJS.verbosity === undefined ? PDFJS.VERBOSITY_LEVELS.warnings : PDFJS.verbosity); +/** + * The maximum supported canvas size in total pixels e.g. width * height. + * The default value is 4096 * 4096. Use -1 for no limit. + * @var {number} + */ +PDFJS.maxCanvasPixels = (PDFJS.maxCanvasPixels === undefined ? + 16777216 : PDFJS.maxCanvasPixels); + /** * Document initialization / loading parameters object. * diff --git a/build/pdf.js b/build/pdf.js index 315751e89..c2dbb2f0f 100644 --- a/build/pdf.js +++ b/build/pdf.js @@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') { (typeof window !== 'undefined' ? window : this).PDFJS = {}; } -PDFJS.version = '1.0.353'; -PDFJS.build = '480e093'; +PDFJS.version = '1.0.355'; +PDFJS.build = '2efbdfe'; (function pdfjsWrapper() { // Use strict in our context only - users might not want it @@ -2481,6 +2481,14 @@ PDFJS.useOnlyCssZoom = (PDFJS.useOnlyCssZoom === undefined ? PDFJS.verbosity = (PDFJS.verbosity === undefined ? PDFJS.VERBOSITY_LEVELS.warnings : PDFJS.verbosity); +/** + * The maximum supported canvas size in total pixels e.g. width * height. + * The default value is 4096 * 4096. Use -1 for no limit. + * @var {number} + */ +PDFJS.maxCanvasPixels = (PDFJS.maxCanvasPixels === undefined ? + 16777216 : PDFJS.maxCanvasPixels); + /** * Document initialization / loading parameters object. * diff --git a/build/pdf.worker.js b/build/pdf.worker.js index b750d7862..97364b01c 100644 --- a/build/pdf.worker.js +++ b/build/pdf.worker.js @@ -21,8 +21,8 @@ if (typeof PDFJS === 'undefined') { (typeof window !== 'undefined' ? window : this).PDFJS = {}; } -PDFJS.version = '1.0.353'; -PDFJS.build = '480e093'; +PDFJS.version = '1.0.355'; +PDFJS.build = '2efbdfe'; (function pdfjsWrapper() { // Use strict in our context only - users might not want it diff --git a/package.json b/package.json index efa668056..b0794e73d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "pdfjs-dist", - "version": "1.0.353", + "version": "1.0.355", "description": "Generic build of Mozilla's PDF.js library.", "keywords": [ "Mozilla", diff --git a/web/compatibility.js b/web/compatibility.js index c39162cbf..b603971e3 100644 --- a/web/compatibility.js +++ b/web/compatibility.js @@ -507,3 +507,12 @@ if (typeof PDFJS === 'undefined') { window.setTimeout(callback, 20); }); })(); + +(function checkCanvasSizeLimitation() { + var isIOS = /(iPad|iPhone|iPod)/g.test(navigator.userAgent); + var isAndroid = /Android/g.test(navigator.userAgent); + if (isIOS || isAndroid) { + // 5MP + PDFJS.maxCanvasPixels = 5242880; + } +})();