Bug 515878: refreshing page scrolls to the top (partial revert) [r=gavin]
authorMark Finkle <mfinkle@mozilla.com>
Mon, 30 Nov 2009 15:52:25 -0500
changeset 65865 ec8e35a4d7a11836bf9744d39f2de96e8bbf8bfd
parent 65864 3f5cfa35b45cb518bb8ecbf2cba13d617e7d4fb1
child 65866 89eea1cc57e2f5398a4449f4fe4bd0700878bd8a
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)
reviewersgavin
bugs515878
Bug 515878: refreshing page scrolls to the top (partial revert) [r=gavin]
mobile/chrome/content/browser.js
--- a/mobile/chrome/content/browser.js
+++ b/mobile/chrome/content/browser.js
@@ -2424,18 +2424,19 @@ ProgressController.prototype = {
   /** This method is called to indicate progress changes for the currently loading page. */
   onProgressChange: function(aWebProgress, aRequest, aCurSelf, aMaxSelf, aCurTotal, aMaxTotal) {
   },
 
   /** This method is called to indicate a change to the current location. */
   onLocationChange: function(aWebProgress, aRequest, aLocationURI) {
     let location = aLocationURI ? aLocationURI.spec : "";
 
-    this._hostChanged = (location != this.browser.lastSpec);
-    if (this._hostChanged) {
+    this._hostChanged = true;
+    
+    if (location != this.browser.lastSpec) {
       this.browser.lastSpec = this.browser.currentURI.spec;
       Browser.removeTransientNotificationsForTab(this._tab);
 
       if (this._tab == Browser.selectedTab) {
         BrowserUI.updateURI();
 
         // We're about to have new page content, to scroll the content area
         // to the top so the new paints will draw correctly.