Closed Bug 770160 Opened 9 years ago Closed 9 years ago
Page title changes for a brief period when a new page is loaded
Nightly Fennec 16.0a1 (2012-07-02) Device: HTC Desire Z OS: Android 2.3.3 Steps to reproduce: 1. Load any page. 2. Load another page. Expected: The new entered page is loaded and the new title is present in the URL bar. Actual: For a brief period (aprox 1s) after the page starts to load the previous page title is displayed in the URL bar.
What's going on here is that we're calling BrowserToolbar's onTabChanged method is calling refresh() when it gets a LOCATION_CHANGE event, and that's asking the tab about its current title, but we weren't clearing the tab's title before firing that LOCATION_CHANGE event. I don't think we actually need to be calling setTitle on LOCATION_CHANGE, since we seem to also be getting a TITLE event for that change, but it seems messy to try to split apart refresh().
Assignee: nobody → margaret.leibovic
Attachment #641263 - Flags: review?(mark.finkle)
Comment on attachment 641263 [details] [diff] [review] patch ># HG changeset patch ># User Margaret Leibovic <email@example.com> ># Date 1342050596 25200 ># Node ID f1c125717f689f05fa865ef6a9af6166feb24d50 ># Parent 5fc6efbc32b2b9146bfd1d5664bfd31786f48d26 >Bug 770160 - Page title changes for a brief period when a new page is loaded > >diff --git a/mobile/android/base/GeckoApp.java b/mobile/android/base/GeckoApp.java >--- a/mobile/android/base/GeckoApp.java >+++ b/mobile/android/base/GeckoApp.java >@@ -821,16 +821,17 @@ abstract public class GeckoApp > tab.setDocumentURI(documentURI); > > // We can get a location change event for the same document with an anchor tag > if (sameDocument) > return; > > tab.setContentType(contentType); > tab.clearFavicon(); >+ tab.updateTitle(null); > tab.updateIdentityData(null); > tab.setReaderEnabled(false); > tab.setAllowZoom(true); > tab.setDefaultZoom(0); > tab.setMinZoom(0); > tab.setMaxZoom(0); > tab.setHasTouchListeners(false); > tab.setCheckerboardColor(Color.WHITE);
Attachment #641263 - Flags: review?(mark.finkle) → review+
Target Milestone: --- → Firefox 16
Comment on attachment 641263 [details] [diff] [review] patch [Approval Request Comment] Bug caused by (feature/regressing bug #): n/a User impact if declined: old page title briefly flashes before a new page is loaded (can look pretty bad on slow connections) Testing completed (on m-c, etc.): just landed on inbound Risk to taking this patch (and alternatives if risky): low-risk, a clean-up call that got missed in the original implementation of the location change handler String or UUID changes made by this patch: n/a
Attachment #641263 - Flags: approval-mozilla-aurora?
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Attachment #641263 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.