+ Took out old paint throttling (which may have been causing more trouble than good) in prep for new paint throttling (some of which is already in)
authorIan Gilman <iangilman@gmail.com>
Fri, 12 Mar 2010 10:04:03 -0800
changeset 49740 1ced5be054caa0d2989ee9f4f985d88745408035
parent 49738 d410d831399b7ec7994ce8341796346c3cb633e6
child 49742 7a6450cfbd721dbdb97a396588559ee395fd2a1c
push id15039
push useredward.lee@engineering.uiuc.edu
push dateThu, 12 Aug 2010 19:47:36 +0000
treeherderautoland@5da28c582cc7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
+ Took out old paint throttling (which may have been causing more trouble than good) in prep for new paint throttling (some of which is already in)
browser/base/content/tabcandy/core/mirror.js
--- a/browser/base/content/tabcandy/core/mirror.js
+++ b/browser/base/content/tabcandy/core/mirror.js
@@ -72,31 +72,35 @@ TabCanvas.prototype = {
     var fromWin = this.tab.contentWindow;
     if( fromWin == null || fromWin.location.protocol == "chrome:") return;
 /*     Utils.log('paint: ' + this.tab.url); */
     var scaler = w/fromWin.innerWidth;
   
     // TODO: Potentially only redraw the dirty rect? (Is it worth it?)
     var now = getMilliseconds();
 /*     Utils.log('now', now - this.lastDraw); */
+/*
     if( this.lastDraw == null || now - this.lastDraw > this.RATE_LIMIT ){
       var startTime = getMilliseconds();
+*/
       ctx.save();
       ctx.scale(scaler, scaler);
       try{
         ctx.drawWindow( fromWin, fromWin.scrollX, fromWin.scrollY, w/scaler, h/scaler, "#fff" );
       } catch(e){
         
       }
       
       ctx.restore();
+/*
       var elapsed = (getMilliseconds()) - startTime;
       //Utils.log( this.window.location.host + " " + elapsed );
       this.lastDraw = getMilliseconds();
     }
+*/
     ctx.restore();      
   },
   
   onPaint: function(evt){
 /*
     if(this.tab.contentWindow == null || this.tab.contentWindow.location.protocol != 'chrome:')
       Utils.trace('on paint', this.tab.contentWindow.location.href);
 */
@@ -186,17 +190,17 @@ TabMirror.prototype = {
 /*           Utils.log('needsPaint', now - mirror.needsPaint, tab.url); */
   /*
           var canvas = $('.thumb', mirror.el).get(0);
           var tabCanvas = $(canvas).data("link");
           tabCanvas.paint();
   */
           mirror.tabCanvas.paint();
   
-          if(mirror.needsPaint + 5000 < now)
+/*           if(mirror.needsPaint + 5000 < now) */
             mirror.needsPaint = 0;
         }
       }
     } catch(e) {
       Utils.error(e);
     }
     
     this._fireNextHeartbeat();