Browse Source

Merge pull request #5674 from Snuffleupagus/avoid-double-childNodes-in-PDFPageView_reset

Avoid getting |childNodes| twice in PDFPageView_reset, by using the variable instead
Tim van der Meij 10 years ago
parent
commit
5db9ebea19
  1. 2
      web/pdf_page_view.js

2
web/pdf_page_view.js

@ -120,7 +120,7 @@ var PDFPageView = (function PDFPageViewClosure() { @@ -120,7 +120,7 @@ var PDFPageView = (function PDFPageViewClosure() {
var currentZoomLayer = this.zoomLayer || null;
var currentAnnotationNode = (keepAnnotations && this.annotationLayer &&
this.annotationLayer.div) || null;
for (var i = div.childNodes.length - 1; i >= 0; i--) {
for (var i = childNodes.length - 1; i >= 0; i--) {
var node = childNodes[i];
if (currentZoomLayer === node || currentAnnotationNode === node) {
continue;

Loading…
Cancel
Save