Closed Bug 509877 Opened 10 years ago Closed 10 years ago

Show awsomescreen on opening new tab

Categories

(Firefox for Android Graveyard :: General, defect)

x86
macOS
defect
Not set

Tracking

(fennec1.0+)

VERIFIED FIXED
Tracking Status
fennec 1.0+ ---

People

(Reporter: madhava, Assigned: stechz)

References

Details

Attachments

(1 file, 1 obsolete file)

Right now, when users open new tabs, they're deposited on a blank white screen (with the titlebar at the top, of course).  In order to actually do whatever prompted them to open a the new tab, they have to, next, tap on the titlebar to bring up the navigation screen (the one with the awesomebar results in it).

Instead, we should focus the titlebar so that the awesomescreen is displayed.

Related to this is bug 477707, which is to show the user that a new tab has opened before the tab area (sidebar) disappears.  Doing that would make the transition less jarring.
Blocks: 477628
tracking-fennec: --- → ?
Assignee: nobody → webapps
tracking-fennec: ? → 1.0+
Duplicate of this bug: 511004
Attached patch v1 (obsolete) — Splinter Review
First, admittedly ugly attempt at showing awesome bar on adding a new tab from UI.  Calling showAutoComplete in addTab after creating a new tab did nothing, not even with a setTimeout(fn, 0), so instead addTab sets a flag that update checks.
Comment on attachment 396538 [details] [diff] [review]
v1

Try to avoid the flag based on some of things we discussed on IRC.
Attachment #396538 - Flags: review-
Attached patch v2Splinter Review
Changed around update a little to avoid unshowing the location bar (and thus the awesomeness).  Flag is no longer needed.
Attachment #396538 - Attachment is obsolete: true
Comment on attachment 396615 [details] [diff] [review]
v2

>+        if (uri.spec != "about:blank") {
>+          this.showToolbar(false);
>+        }

Add a comment telling that we handle "about:blank" as a new tab and open the toolbar elsewhere

> 
>         if (!this._faviconLink)
>           this._faviconLink = uri.prePath + "/favicon.ico";
>@@ -410,7 +412,6 @@
> 
>       case TOOLBARSTATE_LOADING:
>         this.showToolbar();
>-        // Force the mode back to "loading"
>         icons.setAttribute("mode", "loading");

Let's leave that comment in and add the reason why we need it to be "loading"

> 
>         this._favicon.src = "";
>@@ -550,7 +551,8 @@
> 
>   newTab : function newTab(aURI) {
>     //ws.panTo(0, -this.toolbarH);
>-    return Browser.addTab(aURI || "about:blank", true);
>+    let tab = Browser.addTab(aURI || "about:blank", true);
>+    this.showAutoComplete();
>   },

Need to return the "tab" local variable


Excellent patch! Thanks for figuring out a way to avoid the flag. I can make these changes and land it.
pushed with nits: https://hg.mozilla.org/mobile-browser/rev/eb8b305f7a51
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
verified fixed in 20091001 1.9.2 b4 on my n810
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.