[Pkg-javascript-commits] [pdf.js] 68/116: Avoid getting |childNodes| twice in PDFPageView_reset, by using the variable instead

David Prévot taffit at moszumanska.debian.org
Fri Mar 6 16:20:02 UTC 2015


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

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

commit 8471bb32066f016dc22892558deeba886034855c
Author: Jonas Jenwald <jonas.jenwald at gmail.com>
Date:   Mon Jan 26 12:22:09 2015 +0100

    Avoid getting |childNodes| twice in PDFPageView_reset, by using the variable instead
---
 web/pdf_page_view.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/web/pdf_page_view.js b/web/pdf_page_view.js
index 7274829..468d30d 100644
--- a/web/pdf_page_view.js
+++ b/web/pdf_page_view.js
@@ -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;

-- 
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