浏览代码

PDF.js version 1.1.485

Pdf Bot 9 年之前
父节点
当前提交
a5758775ca
共有 6 个文件被更改,包括 14 次插入16 次删除
  1. 1 1
      bower.json
  2. 2 2
      build/pdf.combined.js
  3. 2 2
      build/pdf.js
  4. 2 2
      build/pdf.worker.js
  5. 1 1
      package.json
  6. 6 8
      web/pdf_viewer.js

+ 1 - 1
bower.json

@@ -1,6 +1,6 @@
 {
   "name": "pdfjs-dist",
-  "version": "1.1.483",
+  "version": "1.1.485",
   "main": [
     "build/pdf.js",
     "build/pdf.worker.js"

+ 2 - 2
build/pdf.combined.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.483';
-PDFJS.build = '7cdc6f3';
+PDFJS.version = '1.1.485';
+PDFJS.build = 'e28ad20';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it

+ 2 - 2
build/pdf.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.483';
-PDFJS.build = '7cdc6f3';
+PDFJS.version = '1.1.485';
+PDFJS.build = 'e28ad20';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it

+ 2 - 2
build/pdf.worker.js

@@ -22,8 +22,8 @@ if (typeof PDFJS === 'undefined') {
   (typeof window !== 'undefined' ? window : this).PDFJS = {};
 }
 
-PDFJS.version = '1.1.483';
-PDFJS.build = '7cdc6f3';
+PDFJS.version = '1.1.485';
+PDFJS.build = 'e28ad20';
 
 (function pdfjsWrapper() {
   // Use strict in our context only - users might not want it

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
   "name": "pdfjs-dist",
-  "version": "1.1.483",
+  "version": "1.1.485",
   "description": "Generic build of Mozilla's PDF.js library.",
   "keywords": [
     "Mozilla",

+ 6 - 8
web/pdf_viewer.js

@@ -996,12 +996,10 @@ var PDFPageView = (function PDFPageViewClosure() {
       }
       div.removeAttribute('data-loaded');
 
-      if (keepAnnotations) {
-        if (this.annotationLayer) {
-          // Hide annotationLayer until all elements are resized
-          // so they are not displayed on the already-resized page
-          this.annotationLayer.hide();
-        }
+      if (currentAnnotationNode) {
+        // Hide annotationLayer until all elements are resized
+        // so they are not displayed on the already-resized page
+        this.annotationLayer.hide();
       } else {
         this.annotationLayer = null;
       }
@@ -1172,7 +1170,7 @@ var PDFPageView = (function PDFPageViewClosure() {
       var canvas = document.createElement('canvas');
       canvas.id = 'page' + this.id;
       canvasWrapper.appendChild(canvas);
-      if (this.annotationLayer) {
+      if (this.annotationLayer && this.annotationLayer.div) {
         // annotationLayer needs to stay on top
         div.insertBefore(canvasWrapper, this.annotationLayer.div);
       } else {
@@ -1219,7 +1217,7 @@ var PDFPageView = (function PDFPageViewClosure() {
         textLayerDiv.className = 'textLayer';
         textLayerDiv.style.width = canvas.style.width;
         textLayerDiv.style.height = canvas.style.height;
-        if (this.annotationLayer) {
+        if (this.annotationLayer && this.annotationLayer.div) {
           // annotationLayer needs to stay on top
           div.insertBefore(textLayerDiv, this.annotationLayer.div);
         } else {