Bug 1075531 - Part 1: Return String from ToolbarComponent.getTitle. r=lucasr
authorMichael Comella <michael.l.comella@gmail.com>
Wed, 08 Oct 2014 17:06:01 -0700
changeset 210890 8882bf98a437f42c2bb0a76cda48d8d0b435ca3e
parent 210889 75c3e79b9c7cf81ebe5599e0fdec444fcd6e585a
child 210891 9eb089d7c2b99cd6e8e16b55b11e778f812d29e7
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewerslucasr
bugs1075531
milestone36.0a1
Bug 1075531 - Part 1: Return String from ToolbarComponent.getTitle. r=lucasr
mobile/android/base/tests/components/ToolbarComponent.java
--- a/mobile/android/base/tests/components/ToolbarComponent.java
+++ b/mobile/android/base/tests/components/ToolbarComponent.java
@@ -86,35 +86,35 @@ public class ToolbarComponent extends Ba
     }
     /**
      * Returns the View for the edit cancel button in the browser toolbar.
      */
     private ImageButton getEditCancelButton() {
         return (ImageButton) getToolbarView().findViewById(R.id.edit_cancel);
     }
 
-    private CharSequence getTitle() {
+    private String getTitle() {
         return getTitleHelper(true);
     }
 
     /**
      * Returns the title of the page. Note that this makes no assertions to Toolbar state and
      * may return a value that may never be visible to the user. Callers likely want to use
      * {@link assertTitle} instead.
      */
-    public CharSequence getPotentiallyInconsistentTitle() {
+    public String getPotentiallyInconsistentTitle() {
         return getTitleHelper(false);
     }
 
-    private CharSequence getTitleHelper(final boolean shouldAssertNotEditing) {
+    private String getTitleHelper(final boolean shouldAssertNotEditing) {
         if (shouldAssertNotEditing) {
             assertIsNotEditing();
         }
 
-        return getUrlTitleText().getText();
+        return getUrlTitleText().getText().toString();
     }
 
     private boolean isEditing() {
         return getUrlDisplayLayout().getVisibility() != View.VISIBLE &&
                 getUrlEditText().getVisibility() == View.VISIBLE;
     }
 
     public ToolbarComponent enterEditingMode() {