]> git.parisson.com Git - pdf.js.git/commitdiff
Merge upstream.
authorBrendan Dahl <brendan.dahl@gmail.com>
Thu, 9 Feb 2012 00:31:30 +0000 (16:31 -0800)
committerBrendan Dahl <brendan.dahl@gmail.com>
Thu, 9 Feb 2012 00:31:30 +0000 (16:31 -0800)
1  2 
src/core.js
src/util.js
web/viewer.css
web/viewer.js

diff --cc src/core.js
Simple merge
diff --cc src/util.js
Simple merge
diff --cc web/viewer.css
Simple merge
diff --cc web/viewer.js
index fc7d99cdd7318f7ba7ecfe32123d855bf01de6ed,5a1a1df03d3c2c870ec3eabd6c49e0917e6cb406..2e4c1a767832c53705f72434aff7253305bc83e0
@@@ -801,19 -860,23 +861,23 @@@ var PageView = function pageView(contai
      ctx.restore();
      ctx.translate(-this.x * scale, -this.y * scale);
  
-     this.content.startRendering(ctx,
-       (function pageViewDrawCallback(error) {
-         if (error)
-           PDFView.error('An error occurred while rendering the page.', error);
-         this.stats = content.bench;
-         this.updateStats();
-         if (this.onAfterDraw)
-           this.onAfterDraw();
+     // Rendering area
+     var self = this;
 -    stats.begin = Date.now();
+     this.content.startRendering(ctx, function pageViewDrawCallback(error) {
+       div.removeChild(self.loadingIconDiv);
+       if (error)
+         PDFView.error('An error occurred while rendering the page.', error);
  
-         cache.push(this);
-         callback();
-       }).bind(this), textLayer
-     );
++      self.stats = content.bench;
+       self.updateStats();
+       if (self.onAfterDraw)
+         self.onAfterDraw();
+       cache.push(self);
+       callback();
+     }, textLayer);
  
      setupAnnotations(this.content, this.scale);
      div.setAttribute('data-loaded', true);