Bug 639819 - Update displayport on refresh [r=vingtetun, a=blocking]
authorWes Johnston <wjohnston@mozilla.com>
Tue, 08 Mar 2011 16:09:05 -0800
changeset 67484 a2628acfd43281613b18b81e792a3cec38c19881
parent 67483 36be7ad4c720bae2435d7ecd90e4ea973bfc5d8b
child 67485 36113a4aaa3a20c87cad937b040c962340ebbfb5
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersvingtetun, blocking
bugs639819
Bug 639819 - Update displayport on refresh [r=vingtetun, a=blocking]
mobile/chrome/content/browser.js
--- a/mobile/chrome/content/browser.js
+++ b/mobile/chrome/content/browser.js
@@ -2677,16 +2677,20 @@ Tab.prototype = {
         // If the scale level has not changed we want to be sure the content
         // render correctly since the page refresh process could have been
         // stalled during page load. In this case if the page has the exact
         // same width (like the same page, so by doing 'refresh') and the 
         // page was scrolled the content is just checkerboard at this point
         // and this call ensure we render it correctly.
         browser.getRootView()._updateCacheViewport();
       }
+    } else {
+      // if we are reloading, the page will retain its scale. if it is zoomed
+      // we need to refresh the viewport so that we do not show checkerboard
+      browser.getRootView()._updateCacheViewport();
     }
   },
 
   isDefaultZoomLevel: function isDefaultZoomLevel() {
     return this._browser.scale == this._defaultZoomLevel;
   },
 
   getDefaultZoomLevel: function getDefaultZoomLevel() {