Bug 1111729 - Default to show URL in toolbar instead of page title, and remove preference. r=mcomella
authorMargaret Leibovic <margaret.leibovic@gmail.com>
Mon, 15 Dec 2014 13:21:55 -0800
changeset 221114 51ca6ef957723ade8c801b693fd41a9c7f5d99c9
parent 221113 1731ab46c54612335a3242bea727ae2cc7c8ddc9
child 221115 d6fb576da01d0e184f90bc623233b0f3249a97b6
push id28010
push userkwierso@gmail.com
push dateWed, 24 Dec 2014 00:29:29 +0000
treeherdermozilla-central@8b881bea204a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmcomella
bugs1111729
milestone37.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 1111729 - Default to show URL in toolbar instead of page title, and remove preference. r=mcomella
mobile/android/app/mobile.js
mobile/android/base/locales/en-US/android_strings.dtd
mobile/android/base/preferences/GeckoPreferences.java
mobile/android/base/resources/values/arrays.xml
mobile/android/base/resources/xml/preferences_display.xml
mobile/android/base/strings.xml.in
mobile/android/base/tests/BaseTest.java
mobile/android/base/tests/PixelTest.java
mobile/android/base/tests/SessionTest.java
mobile/android/base/tests/components/ToolbarComponent.java
mobile/android/base/tests/robocop.ini
mobile/android/base/tests/testAboutHomeVisibility.java
mobile/android/base/tests/testAboutPage.java
mobile/android/base/tests/testAddSearchEngine.java
mobile/android/base/tests/testAddonManager.java
mobile/android/base/tests/testAppMenuPathways.java
mobile/android/base/tests/testBookmark.java
mobile/android/base/tests/testBookmarkFolders.java
mobile/android/base/tests/testBookmarkKeyword.java
mobile/android/base/tests/testBookmarklets.java
mobile/android/base/tests/testClearPrivateData.java
mobile/android/base/tests/testGetUserMedia.java
mobile/android/base/tests/testHistory.java
mobile/android/base/tests/testInputConnection.java
mobile/android/base/tests/testPictureLinkContextMenu.java
mobile/android/base/tests/testReaderMode.java
mobile/android/base/tests/testSelectionHandler.java
mobile/android/base/tests/testSessionHistory.java
mobile/android/base/tests/testShareLink.java
mobile/android/base/tests/testTitleBar.java
mobile/android/base/toolbar/ToolbarDisplayLayout.java
mobile/android/base/toolbar/ToolbarPrefs.java
mobile/android/chrome/content/browser.js
--- a/mobile/android/app/mobile.js
+++ b/mobile/android/app/mobile.js
@@ -734,21 +734,16 @@ pref("memory.free_dirty_pages", true);
 pref("layout.imagevisibility.numscrollportwidths", 1);
 pref("layout.imagevisibility.numscrollportheights", 1);
 
 pref("layers.enable-tiles", true);
 
 // Enable the dynamic toolbar
 pref("browser.chrome.dynamictoolbar", true);
 
-// The mode of browser titlebar
-// 0: Show a current page title.
-// 1: Show a current page url.
-pref("browser.chrome.titlebarMode", 0);
-
 // Hide common parts of URLs like "www." or "http://"
 pref("browser.urlbar.trimURLs", true);
 
 #ifdef MOZ_PKG_SPECIAL
 // Disable webgl on ARMv6 because running the reftests takes
 // too long for some reason (bug 843738)
 pref("webgl.disabled", true);
 #endif
--- a/mobile/android/base/locales/en-US/android_strings.dtd
+++ b/mobile/android/base/locales/en-US/android_strings.dtd
@@ -332,20 +332,16 @@ size. -->
 <!ENTITY contextmenu_edit_bookmark "Edit">
 <!ENTITY contextmenu_subscribe "Subscribe to Page">
 <!ENTITY contextmenu_site_settings "Edit Site Settings">
 <!ENTITY contextmenu_top_sites_edit "Edit">
 <!ENTITY contextmenu_top_sites_pin "Pin Site">
 <!ENTITY contextmenu_top_sites_unpin "Unpin Site">
 <!ENTITY contextmenu_add_search_engine "Add a Search Engine">
 
-<!ENTITY pref_titlebar_mode "Title bar">
-<!ENTITY pref_titlebar_mode_title "Show page title">
-<!ENTITY pref_titlebar_mode_url "Show page address">
-
 <!-- Localization note (pref_scroll_title_bar2): Label for setting that controls
      whether or not the dynamic toolbar is enabled. -->
 <!ENTITY pref_scroll_title_bar2 "Full-screen browsing">
 <!ENTITY pref_scroll_title_bar_summary "Hide the &brandShortName; title bar when scrolling down a page">
 
 <!-- Localization note (page_removed): This string appears in a toast message when
      any page is removed frome about:home. This includes pages that are in history,
      bookmarks, or reading list. -->
--- a/mobile/android/base/preferences/GeckoPreferences.java
+++ b/mobile/android/base/preferences/GeckoPreferences.java
@@ -116,17 +116,16 @@ OnSharedPreferenceChangeListener
     private static final String PREFS_MENU_CHAR_ENCODING = "browser.menu.showCharacterEncoding";
     private static final String PREFS_MP_ENABLED = "privacy.masterpassword.enabled";
     private static final String PREFS_UPDATER_AUTODOWNLOAD = "app.update.autodownload";
     private static final String PREFS_GEO_REPORTING = NON_PREF_PREFIX + "app.geo.reportdata";
     private static final String PREFS_GEO_LEARN_MORE = NON_PREF_PREFIX + "geo.learn_more";
     private static final String PREFS_HEALTHREPORT_LINK = NON_PREF_PREFIX + "healthreport.link";
     private static final String PREFS_DEVTOOLS_REMOTE_ENABLED = "devtools.debugger.remote-enabled";
     private static final String PREFS_DISPLAY_REFLOW_ON_ZOOM = "browser.zoom.reflowOnZoom";
-    private static final String PREFS_DISPLAY_TITLEBAR_MODE = "browser.chrome.titlebarMode";
     private static final String PREFS_SYNC = NON_PREF_PREFIX + "sync";
     private static final String PREFS_TRACKING_PROTECTION = "privacy.trackingprotection.enabled";
     private static final String PREFS_TRACKING_PROTECTION_LEARN_MORE = NON_PREF_PREFIX + "trackingprotection.learn_more";
 
     private static final String ACTION_STUMBLER_UPLOAD_PREF = AppConstants.ANDROID_PACKAGE_NAME + ".STUMBLER_PREF";
 
     // This isn't a Gecko pref, even if it looks like one.
     private static final String PREFS_BROWSER_LOCALE = "locale";
@@ -735,22 +734,16 @@ OnSharedPreferenceChangeListener
                     pref.setOnPreferenceClickListener(new OnPreferenceClickListener() {
                         @Override
                         public boolean onPreferenceClick(Preference preference) {
                             GeckoPreferences.this.restoreDefaultSearchEngines();
                             Telemetry.sendUIEvent(TelemetryContract.Event.SEARCH_RESTORE_DEFAULTS, Method.LIST_ITEM);
                             return true;
                         }
                     });
-                } else if (PREFS_DISPLAY_TITLEBAR_MODE.equals(key) &&
-                           NewTabletUI.isEnabled(this)) {
-                    // New tablet always shows URLS, not titles.
-                    preferences.removePreference(pref);
-                    i--;
-                    continue;
                 } else if (handlers.containsKey(key)) {
                     PrefHandler handler = handlers.get(key);
                     if (!handler.setupPref(this, pref)) {
                         preferences.removePreference(pref);
                         i--;
                         continue;
                     }
                 }
--- a/mobile/android/base/resources/values/arrays.xml
+++ b/mobile/android/base/resources/values/arrays.xml
@@ -134,24 +134,16 @@
         <item>@string/pref_update_autodownload_wifi</item>
         <item>@string/pref_update_autodownload_disabled</item>
     </string-array>
     <string-array name="pref_update_autodownload_values">
         <item>enabled</item>
         <item>wifi</item>
         <item>disabled</item>
      </string-array>
-    <string-array name="pref_titlebar_mode_entries">
-        <item>@string/pref_titlebar_mode_title</item>
-        <item>@string/pref_titlebar_mode_url</item>
-    </string-array>
-    <string-array name="pref_titlebar_mode_values">
-        <item>0</item>
-        <item>1</item>
-    </string-array>
     <!-- This value is similar to config_longPressVibePattern in android frameworks/base/core/res/res/values/config.xml-->
     <integer-array name="long_press_vibrate_msec">
         <item>0</item>
         <item>1</item>
         <item>20</item>
         <item>21</item>
     </integer-array>
 </resources>
--- a/mobile/android/base/resources/xml/preferences_display.xml
+++ b/mobile/android/base/resources/xml/preferences_display.xml
@@ -10,22 +10,16 @@
 
     <org.mozilla.gecko.preferences.FontSizePreference
                     android:key="font.size.inflation.minTwips"
                     android:title="@string/pref_text_size"
                     android:positiveButtonText="@string/pref_font_size_set"
                     android:negativeButtonText="@string/button_cancel"
                     android:persistent="false" />
 
-    <ListPreference android:key="browser.chrome.titlebarMode"
-                    android:title="@string/pref_titlebar_mode"
-                    android:entries="@array/pref_titlebar_mode_entries"
-                    android:entryValues="@array/pref_titlebar_mode_values"
-                    android:persistent="false" />
-
     <CheckBoxPreference android:key="browser.chrome.dynamictoolbar"
                         android:title="@string/pref_scroll_title_bar2"
                         android:summary="@string/pref_scroll_title_bar_summary" />
 
     <CheckBoxPreference android:key="media.autoplay.enabled"
                         android:title="@string/pref_media_autoplay_enabled"
                         android:summary="@string/pref_media_autoplay_enabled_summary" />
 
--- a/mobile/android/base/strings.xml.in
+++ b/mobile/android/base/strings.xml.in
@@ -312,20 +312,16 @@
   <string name="contextmenu_edit_bookmark">&contextmenu_edit_bookmark;</string>
   <string name="contextmenu_subscribe">&contextmenu_subscribe;</string>
   <string name="contextmenu_site_settings">&contextmenu_site_settings;</string>
   <string name="contextmenu_top_sites_edit">&contextmenu_top_sites_edit;</string>
   <string name="contextmenu_top_sites_pin">&contextmenu_top_sites_pin;</string>
   <string name="contextmenu_top_sites_unpin">&contextmenu_top_sites_unpin;</string>
   <string name="contextmenu_add_search_engine">&contextmenu_add_search_engine;</string>
 
-  <string name="pref_titlebar_mode">&pref_titlebar_mode;</string>
-  <string name="pref_titlebar_mode_title">&pref_titlebar_mode_title;</string>
-  <string name="pref_titlebar_mode_url">&pref_titlebar_mode_url;</string>
-
   <string name="pref_scroll_title_bar2">&pref_scroll_title_bar2;</string>
   <string name="pref_scroll_title_bar_summary">&pref_scroll_title_bar_summary;</string>
 
   <string name="page_removed">&page_removed;</string>
 
   <string name="bookmark_edit_title">&bookmark_edit_title;</string>
   <string name="bookmark_edit_name">&bookmark_edit_name;</string>
   <string name="bookmark_edit_location">&bookmark_edit_location;</string>
--- a/mobile/android/base/tests/BaseTest.java
+++ b/mobile/android/base/tests/BaseTest.java
@@ -65,17 +65,17 @@ abstract class BaseTest extends BaseRobo
     private static final int MAX_WAIT_ENABLED_TEXT_MS = 10000;
     private static final int MAX_WAIT_HOME_PAGER_HIDDEN_MS = 15000;
     private static final int MAX_WAIT_VERIFY_PAGE_TITLE_MS = 15000;
     public static final int MAX_WAIT_MS = 4500;
     public static final int LONG_PRESS_TIME = 6000;
     private static final int GECKO_READY_WAIT_MS = 180000;
     public static final int MAX_WAIT_BLOCK_FOR_EVENT_DATA_MS = 90000;
 
-    private static final String URL_HTTP_PREFIX = "http://";
+    protected static final String URL_HTTP_PREFIX = "http://";
 
     private Activity mActivity;
     private int mPreferenceRequestID = 0;
     protected Solo mSolo;
     protected Driver mDriver;
     protected Actions mActions;
     protected String mProfile;
     public Device mDevice;
@@ -525,41 +525,34 @@ abstract class BaseTest extends BaseRobo
             }
         }, MAX_WAIT_HOME_PAGER_HIDDEN_MS);
 
         if (!rc) {
             mAsserter.ok(rc, "Verify HomePager is hidden", "HomePager is hidden");
         }
     }
 
-    public final void verifyPageTitle(final String title, String url) {
-        // We are asserting visible state - we shouldn't know if the title is null.
-        mAsserter.isnot(title, null, "The title argument is not null");
+    public final void verifyUrlBarTitle(String url) {
         mAsserter.isnot(url, null, "The url argument is not null");
 
-        // TODO: We should also check the title bar preference.
         final String expected;
-        if (!NewTabletUI.isEnabled(mActivity)) {
-            expected = title;
+        if (StringHelper.ABOUT_HOME_URL.equals(url)) {
+            expected = StringHelper.ABOUT_HOME_TITLE;
+        } else if (url.startsWith(URL_HTTP_PREFIX)) {
+            expected = url.substring(URL_HTTP_PREFIX.length());
         } else {
-            if (StringHelper.ABOUT_HOME_URL.equals(url)) {
-                expected = StringHelper.ABOUT_HOME_TITLE;
-            } else if (url.startsWith(URL_HTTP_PREFIX)) {
-                expected = url.substring(URL_HTTP_PREFIX.length());
-            } else {
-                expected = url;
-            }
+            expected = url;
         }
 
         final TextView urlBarTitle = (TextView) mSolo.getView(R.id.url_bar_title);
         String pageTitle = null;
         if (urlBarTitle != null) {
             // Wait for the title to make sure it has been displayed in case the view
             // does not update fast enough
-            waitForCondition(new VerifyTextViewText(urlBarTitle, title), MAX_WAIT_VERIFY_PAGE_TITLE_MS);
+            waitForCondition(new VerifyTextViewText(urlBarTitle, expected), MAX_WAIT_VERIFY_PAGE_TITLE_MS);
             pageTitle = urlBarTitle.getText().toString();
         }
         mAsserter.is(pageTitle, expected, "Page title is correct");
     }
 
     public final void verifyTabCount(int expectedTabCount) {
         Element tabCount = mDriver.findElement(getActivity(), R.id.tabs_counter);
         String tabCountText = tabCount.getText();
--- a/mobile/android/base/tests/PixelTest.java
+++ b/mobile/android/base/tests/PixelTest.java
@@ -56,17 +56,16 @@ abstract class PixelTest extends BaseTes
             selectMenuItem(StringHelper.NEW_TAB_LABEL);
         }
         tabEventExpecter.blockForEvent();
         contentEventExpecter.blockForEvent();
         waitForText(StringHelper.TITLE_PLACE_HOLDER);
         loadAndPaint(url);
         tabEventExpecter.unregisterListener();
         contentEventExpecter.unregisterListener();
-        mAsserter.ok(waitForText(title), "Checking that the page has loaded", "The page has loaded");
     }
 
     protected final PaintedSurface waitForPaint(Actions.RepeatedEventExpecter expecter) {
         expecter.blockUntilClear(PAINT_CLEAR_DELAY);
         PaintedSurface p = mDriver.getPaintedSurface();
         if (p == null) {
             mAsserter.ok(p != null, "checking that painted surface loaded", 
                  "painted surface loaded");
--- a/mobile/android/base/tests/SessionTest.java
+++ b/mobile/android/base/tests/SessionTest.java
@@ -187,23 +187,27 @@ public abstract class SessionTest extend
                     selectTabAt(currentIndex);
                 } else {
                     mFirstTabVisited = true;
                 }
 
                 (new NavigationWalker<PageInfo>(tab) {
                     @Override
                     public void onItem(PageInfo page, int currentIndex) {
-                        if (page.url.equals(StringHelper.ABOUT_HOME_URL)) {
-                            waitForText("Enter Search or Address");
-                            verifyUrl(page.url);
+                        final String text;
+                        if (StringHelper.ABOUT_HOME_URL.equals(page.url)) {
+                            text = StringHelper.TITLE_PLACE_HOLDER;
+                        } else if (page.url.startsWith(URL_HTTP_PREFIX)) {
+                            text = page.url.substring(URL_HTTP_PREFIX.length());
                         } else {
-                            waitForText(page.title);
-                            verifyPageTitle(page.title, page.url);
+                            text = page.url;
                         }
+                        waitForText(text);
+
+                        verifyUrlBarTitle(page.url);
                     }
 
                     @Override
                     public void goBack() {
                         mNavigation.back();
                     }
 
                     @Override
--- a/mobile/android/base/tests/components/ToolbarComponent.java
+++ b/mobile/android/base/tests/components/ToolbarComponent.java
@@ -41,34 +41,27 @@ public class ToolbarComponent extends Ba
         return this;
     }
 
     public ToolbarComponent assertIsNotEditing() {
         fAssertFalse("The toolbar is not in the editing state", isEditing());
         return this;
     }
 
-    public ToolbarComponent assertTitle(final String title, final String url) {
-        // We are asserting visible state - we shouldn't know if the title is null.
-        fAssertNotNull("The title argument is not null", title);
+    public ToolbarComponent assertTitle(final String url) {
         fAssertNotNull("The url argument is not null", url);
 
-        // TODO: We should also check the title bar preference.
         final String expected;
-        if (!NewTabletUI.isEnabled(mActivity)) {
-            expected = title;
+        final String absoluteURL = NavigationHelper.adjustUrl(url);
+        if (StringHelper.ABOUT_HOME_URL.equals(absoluteURL)) {
+            expected = StringHelper.ABOUT_HOME_TITLE;
+        } else if (absoluteURL.startsWith(URL_HTTP_PREFIX)) {
+            expected = absoluteURL.substring(URL_HTTP_PREFIX.length());
         } else {
-            final String absoluteURL = NavigationHelper.adjustUrl(url);
-            if (StringHelper.ABOUT_HOME_URL.equals(absoluteURL)) {
-                expected = StringHelper.ABOUT_HOME_TITLE;
-            } else if (absoluteURL.startsWith(URL_HTTP_PREFIX)) {
-                expected = absoluteURL.substring(URL_HTTP_PREFIX.length());
-            } else {
-                expected = absoluteURL;
-            }
+            expected = absoluteURL;
         }
 
         fAssertEquals("The Toolbar title is " + expected, expected, getTitle());
         return this;
     }
 
     public ToolbarComponent assertUrl(final String expected) {
         assertIsEditing();
--- a/mobile/android/base/tests/robocop.ini
+++ b/mobile/android/base/tests/robocop.ini
@@ -88,17 +88,16 @@ skip-if = android_version == "10"
 [testSettingsMenuItems]
 # disabled on Android 2.3; bug 979552
 skip-if = android_version == "10"
 # [testShareLink] # see bug 915897
 [testSystemPages]
 # disabled on x86 and 2.3; bug 907383, 979603
 skip-if = android_version == "10" || processor == "x86"
 # [testThumbnails] # see bug 813107
-[testTitleBar]
 # disabled on Android 2.3; bug 979552
 skip-if = android_version == "10"
 # [testVkbOverlap] # see bug 907274
 
 # Using JavascriptTest
 [testAccounts]
 [testAndroidLog]
 [testBrowserDiscovery]
--- a/mobile/android/base/tests/testAboutHomeVisibility.java
+++ b/mobile/android/base/tests/testAboutHomeVisibility.java
@@ -8,44 +8,42 @@ import org.mozilla.gecko.tests.helpers.N
 /**
  * Tests the visibility of about:home after various interactions with the browser.
  */
 public class testAboutHomeVisibility extends UITest {
     public void testAboutHomeVisibility() {
         GeckoHelper.blockForReady();
 
         // Check initial state on about:home.
-        mToolbar.assertTitle(StringHelper.ABOUT_HOME_TITLE, StringHelper.ABOUT_HOME_URL);
+        mToolbar.assertTitle(StringHelper.ABOUT_HOME_URL);
         mAboutHome.assertVisible()
                   .assertCurrentPanel(PanelType.TOP_SITES);
 
         // Go to blank 01.
         NavigationHelper.enterAndLoadUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
         mAboutHome.assertNotVisible();
 
         // Go to blank 02.
         NavigationHelper.enterAndLoadUrl(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
         mAboutHome.assertNotVisible();
 
         // Enter editing mode, where the about:home UI should be visible.
         mToolbar.enterEditingMode();
         mAboutHome.assertVisible()
                   .assertCurrentPanel(PanelType.TOP_SITES);
 
         // Dismiss editing mode, where the about:home UI should be gone.
         mToolbar.dismissEditingMode();
         mAboutHome.assertNotVisible();
 
         // Loading about:home should show about:home again.
         NavigationHelper.enterAndLoadUrl(StringHelper.ABOUT_HOME_URL);
-        mToolbar.assertTitle(StringHelper.ABOUT_HOME_TITLE, StringHelper.ABOUT_HOME_URL);
+        mToolbar.assertTitle(StringHelper.ABOUT_HOME_URL);
         mAboutHome.assertVisible()
                   .assertCurrentPanel(PanelType.TOP_SITES);
 
         // We can navigate to about:home panels by panel UUID.
         mAboutHome.navigateToBuiltinPanelType(PanelType.BOOKMARKS)
                   .assertVisible()
                   .assertCurrentPanel(PanelType.BOOKMARKS);
         mAboutHome.navigateToBuiltinPanelType(PanelType.HISTORY)
--- a/mobile/android/base/tests/testAboutPage.java
+++ b/mobile/android/base/tests/testAboutPage.java
@@ -7,54 +7,42 @@ import org.mozilla.gecko.R;
 
 import android.app.Activity;
 
 /* Tests related to the about: page:
  *  - check that about: loads from the URL bar
  *  - check that about: loads from Settings/About...
  */
 public class testAboutPage extends PixelTest {
-    /**
-     * Ensures the page title matches the given regex (as opposed to String equality).
-     */
-    private void ensureTitleMatches(final String titleRegex, final String urlRegex) {
-        final Activity activity = getActivity();
-        final Element urlBarTitle = mDriver.findElement(activity, R.id.url_bar_title);
-
-        // TODO: We should also be testing what the page title preference value is.
-        final String expectedTitle = NewTabletUI.isEnabled(activity) ? urlRegex : titleRegex;
-        mAsserter.isnot(urlBarTitle, null, "Got the URL bar title");
-        assertMatches(urlBarTitle.getText(), expectedTitle, "page title match");
-    }
 
     public void testAboutPage() {
         blockForGeckoReady();
 
         // Load the about: page and verify its title.
         String url = StringHelper.ABOUT_SCHEME;
         loadAndPaint(url);
 
-        ensureTitleMatches(StringHelper.ABOUT_LABEL, url);
+        verifyUrlBarTitle(url);
 
         // Open a new page to remove the about: page from the current tab.
         url = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
         inputAndLoadUrl(url);
 
         // At this point the page title should have been set.
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, url);
+        verifyUrlBarTitle(url);
 
         // Set up listeners to catch the page load we're about to do.
         Actions.EventExpecter tabEventExpecter = mActions.expectGeckoEvent("Tab:Added");
         Actions.EventExpecter contentEventExpecter = mActions.expectGeckoEvent("DOMContentLoaded");
 
         selectSettingsItem(StringHelper.MOZILLA_SECTION_LABEL, StringHelper.ABOUT_LABEL);
 
         // Wait for the new tab and page to load
         tabEventExpecter.blockForEvent();
         contentEventExpecter.blockForEvent();
 
         tabEventExpecter.unregisterListener();
         contentEventExpecter.unregisterListener();
 
-        // Grab the title to make sure the about: page was loaded.
-        ensureTitleMatches(StringHelper.ABOUT_LABEL, StringHelper.ABOUT_SCHEME);
+        // Make sure the about: page was loaded.
+        verifyUrlBarTitle(StringHelper.ABOUT_SCHEME);
     }
 }
--- a/mobile/android/base/tests/testAddSearchEngine.java
+++ b/mobile/android/base/tests/testAddSearchEngine.java
@@ -55,18 +55,17 @@ public class testAddSearchEngine extends
         final int initialNumSearchEngines = searchEngines.size();
         mAsserter.dumpLog("Search Engines list = " + searchEngines.toString());
 
         // Verify that the number of displayed search engines is the same as the one received through the SearchEngines:Data event.
         verifyDisplayedSearchEnginesCount(initialNumSearchEngines);
 
         // Load the page for the search engine to add.
         inputAndLoadUrl(searchEngineURL);
-        waitForText(StringHelper.ROBOCOP_SEARCH_TITLE);
-        verifyPageTitle(StringHelper.ROBOCOP_SEARCH_TITLE, searchEngineURL);
+        verifyUrlBarTitle(searchEngineURL);
 
         // Used to long-tap on the search input box for the search engine to add.
         getInstrumentation().waitForIdleSync();
         mAsserter.dumpLog("Long Clicking at width = " + String.valueOf(width) + " and height = " + String.valueOf(height));
         mSolo.clickLongOnScreen(width,height);
 
         ImageView view = waitForViewWithDescription(ImageView.class, ADD_SEARCHENGINE_OPTION_TEXT);
         mAsserter.isnot(view, null, "The action mode was opened");
--- a/mobile/android/base/tests/testAddonManager.java
+++ b/mobile/android/base/tests/testAddonManager.java
@@ -31,24 +31,24 @@ public class testAddonManager extends Pi
         // Wait for the new tab and page to load
         tabEventExpecter.blockForEvent();
         contentEventExpecter.blockForEvent();
 
         tabEventExpecter.unregisterListener();
         contentEventExpecter.unregisterListener();
 
         // Verify the url
-        verifyPageTitle(StringHelper.ADDONS_LABEL, aboutAddonsURL);
+        verifyUrlBarTitle(aboutAddonsURL);
 
         // Close the Add-on Manager
         mActions.sendSpecialKey(Actions.SpecialKey.BACK);
 
         // Load the about:addons page and verify it was loaded
         loadAndPaint(aboutAddonsURL);
-        verifyPageTitle(StringHelper.ADDONS_LABEL, aboutAddonsURL);
+        verifyUrlBarTitle(aboutAddonsURL);
 
         // Setup wait for tab to spawn and load
         tabEventExpecter = mActions.expectGeckoEvent("Tab:Added");
         contentEventExpecter = mActions.expectGeckoEvent("DOMContentLoaded");
 
         // Open a new tab
         final String blankURL = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
         addTab(blankURL);
@@ -59,17 +59,17 @@ public class testAddonManager extends Pi
 
         tabEventExpecter.unregisterListener();
         contentEventExpecter.unregisterListener();
 
         // Verify tab count has increased
         verifyTabCount(2);
 
         // Verify the page was opened
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, blankURL);
+        verifyUrlBarTitle(blankURL);
 
         // Addons Manager is not opened 2 separate times when opened from the menu
         selectMenuItem(StringHelper.ADDONS_LABEL);
 
         // Verify tab count not increased
         verifyTabCount(2);
     }
 }
--- a/mobile/android/base/tests/testAppMenuPathways.java
+++ b/mobile/android/base/tests/testAppMenuPathways.java
@@ -43,17 +43,16 @@ public class testAppMenuPathways extends
         Tabs.getInstance().handleMessage("Content:LocationChange", message);
 
         // Save as pdf menu is disabled while playing video.
         mAppMenu.assertMenuItemIsDisabledAndVisible(AppMenuComponent.PageMenuItem.SAVE_AS_PDF);
 
         // The above mock video playback test changes Java state, but not the associated JS state.
         // Navigate to a new page so that the Java state is cleared.
         NavigationHelper.enterAndLoadUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
 
         // Test save as pdf functionality.
         // The following call doesn't wait for the resulting pdf but checks that no exception are thrown.
         // NOTE: save as pdf functionality must be done at the end as it is slow and cause other test operations to fail.
         mAppMenu.pressMenuItem(AppMenuComponent.PageMenuItem.SAVE_AS_PDF);
     }
 }
\ No newline at end of file
--- a/mobile/android/base/tests/testBookmark.java
+++ b/mobile/android/base/tests/testBookmark.java
@@ -26,19 +26,17 @@ public class testBookmark extends AboutH
             mAsserter.ok(mDatabaseHelper.isBookmark(url), "Checking that " + url + " is bookmarked by default", url + " is bookmarked");
         }
 
         mDatabaseHelper.addOrUpdateMobileBookmark(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, BOOKMARK_URL);
         waitForBookmarked(true);
 
         isBookmarkDisplayed(BOOKMARK_URL);
         loadBookmark(BOOKMARK_URL);
-        waitForText(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE);
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
 
         mDatabaseHelper.deleteBookmark(BOOKMARK_URL);
         waitForBookmarked(false);
     }
 
     private void waitForBookmarked(final boolean isBookmarked) {
         boolean bookmarked = waitForTest(new BooleanTest() {
             @Override
--- a/mobile/android/base/tests/testBookmarkFolders.java
+++ b/mobile/android/base/tests/testBookmarkFolders.java
@@ -46,18 +46,17 @@ public class testBookmarkFolders extends
         mAsserter.ok(waitForText(StringHelper.DESKTOP_FOLDER_LABEL), "Going up in the folder hierarchy", "We are back in the main Bookmarks List View");
 
         clickOnBookmarkFolder(StringHelper.DESKTOP_FOLDER_LABEL);
         clickOnBookmarkFolder(StringHelper.TOOLBAR_FOLDER_LABEL);
         isBookmarkDisplayed(DESKTOP_BOOKMARK_URL);
 
         // Open the bookmark from a bookmark folder hierarchy
         loadBookmark(DESKTOP_BOOKMARK_URL);
-        waitForText(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE);
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE, DESKTOP_BOOKMARK_URL);
+        verifyUrlBarTitle(DESKTOP_BOOKMARK_URL);
         openAboutHomeTab(AboutHomeTabs.BOOKMARKS);
 
         // Check that folders don't have a context menu
         boolean success = waitForCondition(new Condition() {
             @Override
             public boolean isSatisfied() {
                 View desktopFolder = getBookmarkFolderView(StringHelper.DESKTOP_FOLDER_LABEL);
                 if (desktopFolder == null) {
--- a/mobile/android/base/tests/testBookmarkKeyword.java
+++ b/mobile/android/base/tests/testBookmarkKeyword.java
@@ -10,19 +10,15 @@ public class testBookmarkKeyword extends
 
         // Add a bookmark, and update it to have a keyword.
         mDatabaseHelper.addOrUpdateMobileBookmark(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, url);
         mDatabaseHelper.updateBookmark(url, StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, keyword);
 
         // Enter the keyword in the urlbar.
         inputAndLoadUrl(keyword);
 
-        // Wait for the page to load.
-        waitForText(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE);
-
         // Make sure the title of the page appeared.
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
 
         // Delete the bookmark to clean up.
         mDatabaseHelper.deleteBookmark(url);
     }
 }
--- a/mobile/android/base/tests/testBookmarklets.java
+++ b/mobile/android/base/tests/testBookmarklets.java
@@ -14,18 +14,17 @@ public class testBookmarklets extends Ab
         final String js = "javascript:alert(12 + .34)";
         boolean alerted;
 
         blockForGeckoReady();
 
         // load a standard page so bookmarklets work
         inputAndLoadUrl(url);
         // Waiting for page title to ensure the page is loaded
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
 
         // verify that user-entered bookmarklets do *not* work
         enterUrl(js);
         mActions.sendSpecialKey(Actions.SpecialKey.ENTER);
         alerted = waitForTest(new BooleanTest() {
             @Override
             public boolean test() {
                 return mSolo.searchButton("OK", true) || mSolo.searchText("12.34", true);
--- a/mobile/android/base/tests/testClearPrivateData.java
+++ b/mobile/android/base/tests/testClearPrivateData.java
@@ -25,17 +25,17 @@ public class testClearPrivateData extend
 
     private void clearHistory() {
 
         // Loading a page and adding a second one as bookmark to have user made bookmarks and history
         String blank1 = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
         String blank2 = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
         String title = StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE;
         inputAndLoadUrl(blank1);
-        verifyPageTitle(title, blank1);
+        verifyUrlBarTitle(blank1);
         mDatabaseHelper.addOrUpdateMobileBookmark(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE, blank2);
 
         // Checking that the history list is not empty
         verifyHistoryCount(1);
 
         //clear and check for device
         checkDevice(title, blank1);
 
@@ -81,17 +81,17 @@ public class testClearPrivateData extend
     // clear private data and verify the device type because for phone there is an extra back action to exit the settings menu
     public void checkDevice(final String title, final String url) {
         clearPrivateData();
         if (mDevice.type.equals("phone")) {
             mActions.sendSpecialKey(Actions.SpecialKey.BACK);
             mAsserter.ok(waitForText(StringHelper.PRIVACY_SECTION_LABEL), "waiting to perform one back", "one back");
         }
         mActions.sendSpecialKey(Actions.SpecialKey.BACK);
-        verifyPageTitle(title, url);
+        verifyUrlBarTitle(url);
     }
 
     // Load a URL, verify that the doorhanger appears and dismiss it
     public void loadCheckDismiss(String option, String url, String message) {
         inputAndLoadUrl(url);
         waitForText(message);
         mAsserter.is(mSolo.searchText(message), true, "Doorhanger:" + message + " has been displayed");
         mSolo.clickOnButton(option);
--- a/mobile/android/base/tests/testGetUserMedia.java
+++ b/mobile/android/base/tests/testGetUserMedia.java
@@ -42,17 +42,17 @@ public class testGetUserMedia extends Ba
         waitForText(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), true, "getUserMedia doorhanger has been displayed");
         waitForSpinner();
         // At least one camera detected
         mAsserter.is(mSolo.searchText(GUM_BACK_CAMERA), true, "getUserMedia found a camera");
         mSolo.clickOnButton(GUM_DENY);
         waitForTextDismissed(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), false, "getUserMedia doorhanger hidden after dismissal");
-        verifyPageTitle(GUM_PAGE_FAILED, GUM_CAMERA_URL);
+        verifyUrlBarTitle(GUM_CAMERA_URL);
 
         // Cameras don't work on the testing hardware, so stream a tab
         inputAndLoadUrl(GUM_TAB_HTTPS_URL);
         waitForText(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), true, "getUserMedia doorhanger has been displayed");
         waitForSpinner();
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), true, "Video source selection available");
         mAsserter.is(mSolo.searchText("MICROPHONE TO USE"), true, "Microphone selection available");
@@ -67,17 +67,17 @@ public class testGetUserMedia extends Ba
         mSolo.clickOnButton(GUM_ALLOW);
         waitForTextDismissed(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), false, "getUserMedia doorhanger hidden after dismissal");
         waitForText(GUM_SELECT_TAB);
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), true, "Tab selection dialog displayed");
         mSolo.clickOnText(GUM_PAGE_TITLE);
         waitForTextDismissed(GUM_SELECT_TAB);
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), false, "Tab selection dialog hidden");
-        verifyPageTitle(GUM_PAGE_VIDEO, GUM_TAB_HTTPS_URL);
+        verifyUrlBarTitle(GUM_TAB_HTTPS_URL);
 
         // Android 2.3 testers fail because of audio issues:
         // E/AudioRecord(  650): Unsupported configuration: sampleRate 44100, format 1, channelCount 1
         // E/libOpenSLES(  650): android_audioRecorder_realize(0x26d7d8) error creating AudioRecord object
         if (Build.VERSION.SDK_INT < Build.VERSION_CODES.ICE_CREAM_SANDWICH) {
             return;
         }
 
@@ -89,33 +89,33 @@ public class testGetUserMedia extends Ba
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), true, "Video source selection available");
         mSolo.clickOnButton(GUM_ALLOW);
         waitForTextDismissed(GUM_MESSAGE);
         waitForText(GUM_SELECT_TAB);
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), true, "Tab selection dialog displayed");
         mSolo.clickOnText(GUM_PAGE_TITLE);
         waitForTextDismissed(GUM_SELECT_TAB);
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), false, "Tab selection dialog hidden");
-        verifyPageTitle(GUM_PAGE_AUDIOVIDEO, GUM_TAB_HTTPS_URL);
+        verifyUrlBarTitle(GUM_TAB_HTTPS_URL);
 
         inputAndLoadUrl(GUM_TAB_HTTPS_URL);
         waitForText(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), true, "getUserMedia doorhanger has been displayed");
 
         waitForSpinner();
         mAsserter.is(mSolo.searchText(GUM_SELECT_TAB), true, "Video source selection available");
         mSolo.clickOnText(GUM_SELECT_TAB);
         waitForText("No Video");
         mAsserter.is(mSolo.searchText("No Video"), true, "'No video' source selection available");
         mSolo.clickOnText("No Video");
         waitForTextDismissed(GUM_SELECT_TAB);
         mSolo.clickOnButton(GUM_ALLOW);
         waitForTextDismissed(GUM_MESSAGE);
         mAsserter.is(mSolo.searchText(GUM_MESSAGE), false, "getUserMedia doorhanger hidden after dismissal");
-        verifyPageTitle(GUM_PAGE_AUDIO, GUM_TAB_HTTPS_URL);
+        verifyUrlBarTitle(GUM_TAB_HTTPS_URL);
     }
 
     // wait for a Spinner view that is clickable
     private void waitForSpinner() {
         waitForCondition(new Condition() {
             @Override
             public boolean isSatisfied() {
                 for (Spinner view : mSolo.getCurrentViews(Spinner.class)) {
--- a/mobile/android/base/tests/testHistory.java
+++ b/mobile/android/base/tests/testHistory.java
@@ -12,21 +12,21 @@ public class testHistory extends AboutHo
     public void testHistory() {
         blockForGeckoReady();
 
         String url = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
         String url2 = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
         String url3 = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_03_URL);
 
         inputAndLoadUrl(url);
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL, url);
+        verifyUrlBarTitle(url);
         inputAndLoadUrl(url2);
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_URL, url2);
+        verifyUrlBarTitle(url2);
         inputAndLoadUrl(url3);
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_03_URL, url3);
+        verifyUrlBarTitle(url3);
 
         openAboutHomeTab(AboutHomeTabs.HISTORY);
 
         final ListView hList = findListViewWithTag(HomePager.LIST_TAG_HISTORY);
         mAsserter.is(waitForNonEmptyListToLoad(hList), true, "list is properly loaded");
 
         // Click on the history item and wait for the page to load
         // wait for the history list to be populated
@@ -57,12 +57,12 @@ public class testHistory extends AboutHo
             }
         }, MAX_WAIT_MS);
 
         mAsserter.isnot(mFirstChild, null, "Got history item");
         mSolo.clickOnView(mFirstChild);
 
         // The first item here (since it was just visited) should be a "Switch to tab" item
         // i.e. don't expect a DOMContentLoaded event
-        verifyPageTitle(StringHelper.ROBOCOP_BLANK_PAGE_03_URL, StringHelper.ROBOCOP_BLANK_PAGE_03_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_BLANK_PAGE_03_URL);
         verifyUrl(url3);
     }
 }
--- a/mobile/android/base/tests/testInputConnection.java
+++ b/mobile/android/base/tests/testInputConnection.java
@@ -21,17 +21,17 @@ public class testInputConnection extends
 
     private static final String INITIAL_TEXT = "foo";
 
     public void testInputConnection() throws InterruptedException {
         GeckoHelper.blockForReady();
 
         final String url = StringHelper.ROBOCOP_INPUT_URL + "#" + INITIAL_TEXT;
         NavigationHelper.enterAndLoadUrl(url);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_INPUT_TITLE, url);
+        mToolbar.assertTitle(url);
 
         mGeckoView.mTextInput
             .waitForInputConnection()
             .testInputConnection(new BasicInputConnectionTest());
     }
 
     private class BasicInputConnectionTest implements InputConnectionTest {
         @Override
--- a/mobile/android/base/tests/testPictureLinkContextMenu.java
+++ b/mobile/android/base/tests/testPictureLinkContextMenu.java
@@ -13,17 +13,17 @@ public class testPictureLinkContextMenu 
     private static final String imageTitle = "^Image$";
 
     public void testPictureLinkContextMenu() {
         blockForGeckoReady();
 
         PICTURE_PAGE_URL=getAbsoluteUrl(StringHelper.ROBOCOP_PICTURE_LINK_URL);
         BLANK_PAGE_URL=getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
         loadAndPaint(PICTURE_PAGE_URL);
-        verifyPageTitle(PICTURE_PAGE_TITLE, PICTURE_PAGE_URL);
+        verifyUrlBarTitle(PICTURE_PAGE_URL);
 
         switchTabs(imageTitle);
         verifyContextMenuItems(photoMenuItems);
         verifyTabs(tabs);
         switchTabs(imageTitle);
         verifyCopyOption(photoMenuItems[0], "Firefox.jpg"); // Test the "Copy Image Location" option
         switchTabs(imageTitle);
         verifyShareOption(photoMenuItems[1], PICTURE_PAGE_TITLE); // Test the "Share Image" option
--- a/mobile/android/base/tests/testReaderMode.java
+++ b/mobile/android/base/tests/testReaderMode.java
@@ -68,17 +68,17 @@ public class testReaderMode extends Abou
         // Changing devices orientation to be sure that all devices are in portrait when will access the reader toolbar
         mSolo.setActivityOrientation(Solo.PORTRAIT);
         faviconExpecter.blockForEvent();
         faviconExpecter.unregisterListener();
         contentPageShowExpecter.blockForEvent();
         contentPageShowExpecter.unregisterListener();
         paintExpecter.blockUntilClear(EVENT_CLEAR_DELAY_MS);
         paintExpecter.unregisterListener();
-        verifyPageTitle(StringHelper.ROBOCOP_TEXT_PAGE_TITLE, StringHelper.ROBOCOP_TEXT_PAGE_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_TEXT_PAGE_URL);
 
         // Open the share menu for the reader toolbar
         height = mDriver.getGeckoTop() + mDriver.getGeckoHeight() - 10;
         width = mDriver.getGeckoLeft() + mDriver.getGeckoWidth() - 10;
         mAsserter.dumpLog("Long Clicking at width = " + String.valueOf(width) + " and height = " + String.valueOf(height));
         mSolo.clickOnScreen(width,height);
         mAsserter.ok(mSolo.waitForText("Share via"), "Waiting for the share menu", "The share menu is present");
         mActions.sendSpecialKey(Actions.SpecialKey.BACK); // Close the share menu
@@ -129,25 +129,25 @@ public class testReaderMode extends Abou
         openAboutHomeTab(AboutHomeTabs.READING_LIST);
         list = findListViewWithTag(HomePager.LIST_TAG_READING_LIST);
         child = list.getChildAt(childNo-1);
         mAsserter.ok(child != null, "Verify if the page is present to your Reading List", "The page is present in your Reading List");
         contentEventExpecter = mActions.expectGeckoEvent("DOMContentLoaded");
         mSolo.clickOnView(child);
         contentEventExpecter.blockForEvent();
         contentEventExpecter.unregisterListener();
-        verifyPageTitle(StringHelper.ROBOCOP_TEXT_PAGE_TITLE, StringHelper.ROBOCOP_TEXT_PAGE_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_TEXT_PAGE_URL);
 
         // Verify that we are in reader mode and remove the page from Reading List
         height = mDriver.getGeckoTop() + mDriver.getGeckoHeight() - 10;
         width = mDriver.getGeckoLeft() + 50;
         mAsserter.dumpLog("Long Clicking at width = " + String.valueOf(width) + " and height = " + String.valueOf(height));
         mSolo.clickOnScreen(width,height);
         mAsserter.ok(mSolo.waitForText("Page removed from your Reading List"), "Waiting for the page to removed from your Reading List", "The page is removed from your Reading List");
-        verifyPageTitle(StringHelper.ROBOCOP_TEXT_PAGE_TITLE, StringHelper.ROBOCOP_TEXT_PAGE_URL);
+        verifyUrlBarTitle(StringHelper.ROBOCOP_TEXT_PAGE_URL);
 
         //Check if the Reading List is empty
         openAboutHomeTab(AboutHomeTabs.READING_LIST);
         list = findListViewWithTag(HomePager.LIST_TAG_READING_LIST);
         child = list.getChildAt(childNo-1);
         mAsserter.ok(child == null, "Verify if the Reading List is empty", "The Reading List is empty");
     }
 
--- a/mobile/android/base/tests/testSelectionHandler.java
+++ b/mobile/android/base/tests/testSelectionHandler.java
@@ -13,17 +13,17 @@ import org.json.JSONObject;
 public class testSelectionHandler extends UITest {
 
     public void testSelectionHandler() {
         GeckoHelper.blockForReady();
 
         Actions.EventExpecter robocopTestExpecter = getActions().expectGeckoEvent("Robocop:testSelectionHandler");
         final String url = "chrome://roboextender/content/testSelectionHandler.html";
         NavigationHelper.enterAndLoadUrl(url);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_SELECTION_HANDLER_TITLE, url);
+        mToolbar.assertTitle(url);
 
         while (!test(robocopTestExpecter)) {
             // do nothing
         }
 
         robocopTestExpecter.unregisterListener();
     }
 
--- a/mobile/android/base/tests/testSessionHistory.java
+++ b/mobile/android/base/tests/testSessionHistory.java
@@ -7,35 +7,31 @@ import org.mozilla.gecko.tests.helpers.N
  * Tests that navigating through session history (ex: forward, back) sets the correct UI state.
  */
 public class testSessionHistory extends UITest {
     public void testSessionHistory() {
         GeckoHelper.blockForReady();
 
         String url = StringHelper.ROBOCOP_BLANK_PAGE_01_URL;
         NavigationHelper.enterAndLoadUrl(url);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE, url);
+        mToolbar.assertTitle(url);
 
         url = StringHelper.ROBOCOP_BLANK_PAGE_02_URL;
         NavigationHelper.enterAndLoadUrl(url);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE, url);
+        mToolbar.assertTitle(url);
 
         url = StringHelper.ROBOCOP_BLANK_PAGE_03_URL;
         NavigationHelper.enterAndLoadUrl(url);
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_03_TITLE, url);
+        mToolbar.assertTitle(url);
 
         NavigationHelper.goBack();
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
 
         NavigationHelper.goBack();
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
 
         NavigationHelper.goForward();
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
 
         NavigationHelper.reload();
-        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_TITLE,
-                StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
+        mToolbar.assertTitle(StringHelper.ROBOCOP_BLANK_PAGE_02_URL);
     }
 }
--- a/mobile/android/base/tests/testShareLink.java
+++ b/mobile/android/base/tests/testShareLink.java
@@ -32,17 +32,17 @@ public class testShareLink extends About
         url = getAbsoluteUrl(StringHelper.ROBOCOP_BIG_LINK_URL);
         ArrayList<String> shareOptions;
         blockForGeckoReady();
 
         // FIXME: This is a temporary hack workaround for a permissions problem.
         openAboutHomeTab(AboutHomeTabs.READING_LIST);
 
         inputAndLoadUrl(url);
-        verifyPageTitle(urlTitle, url); // Waiting for page title to ensure the page is loaded
+        verifyUrlBarTitle(url); // Waiting for page title to ensure the page is loaded
 
         selectMenuItem(StringHelper.SHARE_LABEL);
         if (Build.VERSION.SDK_INT >= 14) {
             // Check for our own sync in the submenu.
             waitForText("Sync$");
         } else {
             waitForText("Share via");
         }
deleted file mode 100644
--- a/mobile/android/base/tests/testTitleBar.java
+++ /dev/null
@@ -1,58 +0,0 @@
-package org.mozilla.gecko.tests;
-
-import org.mozilla.gecko.Actions;
-import org.mozilla.gecko.NewTabletUI;
-
-/**
- * This patch tests the option that shows the full URL and title in the URL Bar
- */
-
-public class testTitleBar extends PixelTest {
-    public void testTitleBar() {
-        // Because there is no title bar option on new tablet, we don't need to run this test.
-        if (NewTabletUI.isEnabled(getActivity())) {
-            return;
-        }
-
-        blockForGeckoReady();
-        checkOption();
-    }
-
-    public void checkOption() {
-
-        String blank1 = getAbsoluteUrl(StringHelper.ROBOCOP_BLANK_PAGE_01_URL);
-        String title = StringHelper.ROBOCOP_BLANK_PAGE_01_TITLE;
-
-        // Loading a page
-        inputAndLoadUrl(blank1);
-        verifyPageTitle(title, blank1);
-
-        // Ensure the full URL is displayed in the URL Bar
-        selectOption(StringHelper.SHOW_PAGE_ADDRESS_LABEL);
-        inputAndLoadUrl(blank1);
-        verifyUrl(blank1);
-
-        // Ensure the title is displayed in the URL Bar
-        selectOption(StringHelper.SHOW_PAGE_TITLE_LABEL);
-        inputAndLoadUrl(blank1);
-        verifyPageTitle(title, blank1);
-    }
-
-    // Entering settings, changing the options: show title/page address option and verifing the device type because for phone there is an extra back action to exit the settings menu
-    public void selectOption(String option) {
-        selectSettingsItem(StringHelper.DISPLAY_SECTION_LABEL, StringHelper.TITLE_BAR_LABEL);
-        mAsserter.ok(waitForText(StringHelper.SHOW_PAGE_TITLE_LABEL), "Waiting for the pop-up to open", "Pop up with the options was openend");
-        mSolo.clickOnText(option);
-        mAsserter.ok(waitForText(StringHelper.CHARACTER_ENCODING_LABEL), "Waiting to press the option", "The pop-up is dismissed once clicked");
-        if (mDevice.type.equals("phone")) {
-            mActions.sendSpecialKey(Actions.SpecialKey.BACK);
-            mAsserter.ok(waitForText(StringHelper.CUSTOMIZE_SECTION_LABEL), "Waiting to perform one back", "One back performed");
-            mActions.sendSpecialKey(Actions.SpecialKey.BACK);
-            mAsserter.ok(waitForText(StringHelper.ROBOCOP_BLANK_PAGE_01_URL), "Waiting to exit settings", "Exit settings done");
-        }
-        else {
-            mActions.sendSpecialKey(Actions.SpecialKey.BACK);
-            mAsserter.ok(waitForText(StringHelper.ROBOCOP_BLANK_PAGE_01_URL), "Waiting to exit settings", "Exit settings done");
-        }
-    }
-}
--- a/mobile/android/base/toolbar/ToolbarDisplayLayout.java
+++ b/mobile/android/base/toolbar/ToolbarDisplayLayout.java
@@ -352,22 +352,16 @@ public class ToolbarDisplayLayout extend
 
             final SpannableStringBuilder builder = new SpannableStringBuilder(title);
             builder.setSpan(mBlockedColor, 0, title.length(), Spannable.SPAN_INCLUSIVE_INCLUSIVE);
 
             setTitle(builder);
             return;
         }
 
-        // If the pref to show the URL isn't set, just use the tab's display title.
-        if (!mPrefs.shouldShowUrl(mActivity) || url == null) {
-            setTitle(tab.getDisplayTitle());
-            return;
-        }
-
         CharSequence title = url;
         if (mPrefs.shouldTrimUrls()) {
             title = StringUtils.stripCommonSubdomains(StringUtils.stripScheme(url));
         }
 
         final String baseDomain = tab.getBaseDomain();
         if (!TextUtils.isEmpty(baseDomain)) {
             final SpannableStringBuilder builder = new SpannableStringBuilder(title);
--- a/mobile/android/base/toolbar/ToolbarPrefs.java
+++ b/mobile/android/base/toolbar/ToolbarPrefs.java
@@ -10,48 +10,41 @@ import org.mozilla.gecko.PrefsHelper;
 import org.mozilla.gecko.Tab;
 import org.mozilla.gecko.Tabs;
 import org.mozilla.gecko.util.ThreadUtils;
 
 import android.content.Context;
 
 class ToolbarPrefs {
     private static final String PREF_AUTOCOMPLETE_ENABLED = "browser.urlbar.autocomplete.enabled";
-    private static final String PREF_TITLEBAR_MODE = "browser.chrome.titlebarMode";
     private static final String PREF_TRIM_URLS = "browser.urlbar.trimURLs";
 
     private static final String[] PREFS = {
         PREF_AUTOCOMPLETE_ENABLED,
-        PREF_TITLEBAR_MODE,
         PREF_TRIM_URLS
     };
 
     private final TitlePrefsHandler HANDLER = new TitlePrefsHandler();
 
     private volatile boolean enableAutocomplete;
-    private volatile boolean showUrl;
     private volatile boolean trimUrls;
 
     private Integer prefObserverId;
 
     ToolbarPrefs() {
         // Skip autocompletion while Gecko is loading.
         // We will get the correct pref value once Gecko is loaded.
         enableAutocomplete = false;
         trimUrls = true;
     }
 
     boolean shouldAutocomplete() {
         return enableAutocomplete;
     }
 
-    boolean shouldShowUrl(final Context context) {
-        return showUrl || NewTabletUI.isEnabled(context);
-    }
-
     boolean shouldTrimUrls() {
         return trimUrls;
     }
 
     void open() {
         if (prefObserverId == null) {
             prefObserverId = PrefsHelper.getPrefs(PREFS, HANDLER);
         }
@@ -74,30 +67,16 @@ class ToolbarPrefs {
                     tabs.notifyListeners(tab, Tabs.TabEvents.TITLE);
                 }
             }
         });
     }
 
     private class TitlePrefsHandler extends PrefsHelper.PrefHandlerBase {
         @Override
-        public void prefValue(String pref, String str) {
-            if (PREF_TITLEBAR_MODE.equals(pref)) {
-                // Handles PREF_TITLEBAR_MODE, which is always a string.
-                int value = Integer.parseInt(str);
-                boolean shouldShowUrl = (value == 1);
-
-                if (shouldShowUrl != showUrl) {
-                    showUrl = shouldShowUrl;
-                    triggerTitleChangeListener();
-                }
-            }
-        }
-
-        @Override
         public void prefValue(String pref, boolean value) {
             if (PREF_AUTOCOMPLETE_ENABLED.equals(pref)) {
                 enableAutocomplete = value;
 
             } else if (PREF_TRIM_URLS.equals(pref)) {
                 // Handles PREF_TRIM_URLS, which should usually be a boolean.
                 if (value != trimUrls) {
                     trimUrls = value;
--- a/mobile/android/chrome/content/browser.js
+++ b/mobile/android/chrome/content/browser.js
@@ -1333,17 +1333,16 @@ var BrowserApp = {
 
       // Some Gecko preferences use integers or strings to reference
       // state instead of directly representing the value.
       // Since the Java UI uses the type to determine which ui elements
       // to show and how to handle them, we need to normalize these
       // preferences to the correct type.
       switch (prefName) {
         // (string) index for determining which multiple choice value to display.
-        case "browser.chrome.titlebarMode":
         case "network.cookie.cookieBehavior":
         case "font.size.inflation.minTwips":
         case "home.sync.updateMode":
           pref.type = "string";
           pref.value = pref.value.toString();
           break;
       }
 
@@ -1384,17 +1383,16 @@ var BrowserApp = {
       // Crash reporter preference is in a service; set and return.
       case "datareporting.crashreporter.submitEnabled":
         CrashReporter.submitReports = json.value;
         return;
 #endif
       // When sending to Java, we normalized special preferences that use
       // integers and strings to represent booleans. Here, we convert them back
       // to their actual types so we can store them.
-      case "browser.chrome.titlebarMode":
       case "network.cookie.cookieBehavior":
       case "font.size.inflation.minTwips":
       case "home.sync.updateMode":
         json.type = "int";
         json.value = parseInt(json.value);
         break;
     }