Closed Bug 605303 Opened 14 years ago Closed 14 years ago

Long Page title is centered in the url bar instead of left justified

Categories

(Firefox for Android Graveyard :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: aakashd, Assigned: mbrubeck)

Details

Attachments

(3 files)

Build Id:
Mozilla/5.0 (Android; Linux armv71; rv:2.0b8pre) Gecko/20101018 Namoroka/4.0b8pre Fennec/4.0b2pre

Steps to Reproduce:
1. Go to www.slashdot.org
2. Wait for the page to load

Actual Results:
The page title on the urlbar is centered.

Expected Results: 
The page title should be left-justified.
tracking-fennec: --- → ?
Attached image screenshot
Seem so be fixed
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Nope, seeing this in portrait mode on the N1 and Vibrant.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
To add more detail,

After the page has finished loading, the urlbar disappears. If you bring the urlbar back into view by panning up. The behavior will be seen.


Also, this issue will be seen when you orient from portrait -> landscape -> portrait and then open the tab sidebar.
Attached image Droid 2 Screenshot
The spacing on the portrait mode on the right hand side is less than that of the left hand side.
Assignee: nobody → mbrubeck
Status: REOPENED → ASSIGNED
I can reproduce this bug sometimes by clicking in the urlbar and dragging sidebars in and out.  I'm not sure the exact steps to reproduce.  Sometimes it happens on initial page load.

It seems that the caret is at the end of the text in the urlbar textbox (even though the textbox is readonly and the caret is not visible).  This causes the text to scroll so that the end is visible.  Also, the title sometimes appears selected.

Setting the selectionStart = selectionEnd = 0 for the input field seems to fix this, but I haven't found the right place to set it that fixes it all the time.

Remind me again why we use the textbox to display the title, rather than hide it and show a <label>?


(In reply to comment #5)
> Created attachment 484467 [details]
> Droid 2 Screenshot
> 
> The spacing on the portrait mode on the right hand side is less than that of
> the left hand side.

This is expected - we don't apply padding where text is clipped at the end of the textbox.
Attached patch patchSplinter Review
This fixes the bug by resetting the selectionStart/selectionEnd when the value or the readOnly property changes.  Feels kind of hacky - after beta 2 I'd like to see if we can clean this up by replacing the textfield with a label instead.
Attachment #485168 - Flags: review?(mark.finkle)
Comment on attachment 485168 [details] [diff] [review]
patch

File a bug on doing a better fix? Land for b2 please.
Attachment #485168 - Flags: review?(mark.finkle) → review+
http://hg.mozilla.org/mobile-browser/rev/d0c7c3011fda
Status: ASSIGNED → RESOLVED
Closed: 14 years ago14 years ago
Resolution: --- → FIXED
verified FIXED on builds:
Mozilla/5.0 (Maemo; Linux armv71; rv:2.0b8pre) Gecko/20101022 Namoroka/4.0b8pre Fennec/4.0b2pre

and

Mozilla/5.0 (Android; Linux armv71; rv:2.0b8pre) Gecko/20101022 Namoroka/4.0b8pre Fennec/4.0b2pre
Status: RESOLVED → VERIFIED
tracking-fennec: ? → ---
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: