Closed
Bug 643301
Opened 12 years ago
Closed 12 years ago
The notification about extensions becoming disabled appears half off screen
Categories
(Firefox for Android Graveyard :: Extension Compatibility, defect)
Tracking
(firefox5 fixed, fennec5+)
VERIFIED
FIXED
People
(Reporter: mossop, Assigned: mbrubeck)
References
Details
(Whiteboard: [has patch])
Attachments
(1 file)
3.31 KB,
patch
|
mfinkle
:
review+
|
Details | Diff | Splinter Review |
Just updated to Fennec 4.1a1pre and it had to disable one of my extensions (URL Fixer). It displayed a notification about this on startup but it was half off the right of the screen so I couldn't really read it.
Assignee | ||
Comment 1•12 years ago
|
||
I'm seeing this too; seems to be Android-only.
Assignee: nobody → mbrubeck
tracking-fennec: --- → ?
Assignee | ||
Comment 2•12 years ago
|
||
The problem is in this code. During Browser.startup(), window.innerWidth is not set correctly yet (it is equal to 1) so the calculation is wrong: http://mxr.mozilla.org/mobile-browser/source/chrome/content/AlertsHelper.js#51
Blocks: 634173
Assignee | ||
Comment 3•12 years ago
|
||
Fixes the problem by moving the code to the UIReadyDelayed handler. We don't want to show alerts before the UI is ready. Also adds a warning to the alert service, in case anyone tries this again.
Attachment #521294 -
Flags: review?(mark.finkle)
Assignee | ||
Updated•12 years ago
|
Whiteboard: [has patch]
Comment 4•12 years ago
|
||
Comment on attachment 521294 [details] [diff] [review] patch > #ifdef ANDROID > let offset = (window.innerWidth - container.width) / 2; >- if (container.hasAttribute("left")) >+ if (offset < 0) >+ Cu.reportError("showAlertNotification called before the window is ready"); >+ else if (container.hasAttribute("left")) > container.setAttribute("left", offset); > else > container.setAttribute("right", offset); Can we add the new if (offset) check as a standalone if block, and leave the existing if block alone?
Attachment #521294 -
Flags: review?(mark.finkle) → review+
Comment 5•12 years ago
|
||
(In reply to comment #4) > Can we add the new if (offset) check as a standalone if block, and leave the > existing if block alone? Or does the new if check actually have an impact on the position of the toaster alert?
Assignee | ||
Comment 6•12 years ago
|
||
(In reply to comment #5) > Or does the new if check actually have an impact on the position of the toaster > alert? The new "if" check prevents the toaster alert from ending up off-screen. (If someone else makes this mistake, it'll end up with the Maemo-style positioning instead.)
Assignee | ||
Comment 7•12 years ago
|
||
http://hg.mozilla.org/mobile-browser/rev/03227d0d7fc3
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Comment 8•12 years ago
|
||
Verified on build: Mozilla /5.0 (Android;Linux armv7l;rv:2.2a1pre) Gecko/20110401 Firefox/4.2a1pre Fennec /4.1a1pre Device: HTC Desire (Android 2.2)
Status: RESOLVED → VERIFIED
Updated•12 years ago
|
tracking-fennec: ? → 5+
status-firefox5:
--- → fixed
You need to log in
before you can comment on or make changes to this bug.
Description
•