Bug 944047 - Change the initialisation order in BrowserElementPanning.js r=cwiiis
authorVivien Nicolas <vnicolas@mozilla.com>
Thu, 05 Dec 2013 20:47:19 +0000
changeset 174741 015be0f83e7a38d3f92081fe3c42daeec4ad3155
parent 174740 1c645ff95f2c9db5339bcf5bf8df5f914edf8a5a
child 174742 1689fa499c1ce39ec6ffd8b21ddd9d1464b4a6c6
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerscwiiis
bugs944047
milestone28.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 944047 - Change the initialisation order in BrowserElementPanning.js r=cwiiis Change the order of initialisation in BrowserElementPanning.js so that TabChild::IsAsyncPanZoomEnabled isn't called before TabChild::InitRenderingState.
dom/browser-element/BrowserElementChild.js
dom/browser-element/BrowserElementPanning.js
--- a/dom/browser-element/BrowserElementChild.js
+++ b/dom/browser-element/BrowserElementChild.js
@@ -30,13 +30,18 @@ if (!('BrowserElementIsPreloaded' in thi
     }
   } catch (e) {
   }
   // Those are produc-specific files that's sometimes unavailable.
   try {
     Services.scriptloader.loadSubScript("chrome://browser/content/ErrorPage.js");
   } catch (e) {
   }
+
   Services.scriptloader.loadSubScript("chrome://global/content/BrowserElementPanning.js");
+  ContentPanning.init();
+
   Services.scriptloader.loadSubScript("chrome://global/content/BrowserElementChildPreload.js");
+} else {
+  ContentPanning.init();
 }
 
 var BrowserElementIsReady = true;
--- a/dom/browser-element/BrowserElementPanning.js
+++ b/dom/browser-element/BrowserElementPanning.js
@@ -595,18 +595,16 @@ const ContentPanning = {
     this._activationTimer.cancel();
 
     if (this.panning) {
       KineticPanning.start(this);
     }
   }
 };
 
-ContentPanning.init();
-
 // Min/max velocity of kinetic panning. This is in pixels/millisecond.
 const kMinVelocity = 0.2;
 const kMaxVelocity = 6;
 
 // Constants that affect the "friction" of the scroll pane.
 const kExponentialC = 1000;
 const kPolynomialC = 100 / 1000000;