Bug 727140 - OOM due to zoom of background tabs going to zero. This prevents viewport resizing happening on background tabs which should be a bit faster. r=pcwalton
authorDoug Turner <dougt@dougt.org>
Fri, 17 Feb 2012 23:08:47 -0800
changeset 92484 70c7baef22dfd3bdd14bda29703813d7b167c232
parent 92483 c0c112a42001787f34bce291bd29962aac31f24d
child 92485 e45688c8531c0fa5639b61b32167d57ff4cb949c
push idunknown
push userunknown
push dateunknown
reviewerspcwalton
bugs727140
milestone13.0a1
Bug 727140 - OOM due to zoom of background tabs going to zero. This prevents viewport resizing happening on background tabs which should be a bit faster. r=pcwalton
mobile/android/chrome/content/browser.js
--- a/mobile/android/chrome/content/browser.js
+++ b/mobile/android/chrome/content/browser.js
@@ -3214,18 +3214,17 @@ var ViewportHandler = {
       height: height,
       autoSize: autoSize,
       allowZoom: allowZoom,
       autoScale: true
     };
   },
 
   onResize: function onResize() {
-    for (let i = 0; i < BrowserApp.tabs.length; i++)
-      BrowserApp.tabs[i].updateViewportSize();
+    Tabs.getInstance().getSelectedTab().updateViewportSize();        
   },
 
   clamp: function(num, min, max) {
     return Math.max(min, Math.min(max, num));
   },
 
   // The device-pixel-to-CSS-px ratio used to adjust meta viewport values.
   // This is higher on higher-dpi displays, so pages stay about the same physical size.