Last Comment Bug 686469 - Tab-modal alert can overflow the browser window
: Tab-modal alert can overflow the browser window
Status: VERIFIED FIXED
[qa!]
: regression, verified-aurora, verified-beta
Product: Toolkit
Classification: Components
Component: XUL Widgets (show other bugs)
: 7 Branch
: All All
: -- normal (vote)
: mozilla10
Assigned To: Dão Gottwald [:dao]
:
Mentors:
: 689503 (view as bug list)
Depends on:
Blocks: 668500
  Show dependency treegraph
 
Reported: 2011-09-13 09:23 PDT by Michał
Modified: 2013-11-12 00:56 PST (History)
13 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
wontfix
affected
fixed


Attachments
Screenshot (14.16 KB, image/png)
2011-09-13 09:23 PDT, Michał
no flags Details
TestCase (926 bytes, text/html)
2011-09-13 09:24 PDT, Michał
no flags Details
patch (1.60 KB, patch)
2011-09-19 05:57 PDT, Dão Gottwald [:dao]
dolske: review+
asa: approval‑mozilla‑aurora+
christian: approval‑mozilla‑beta-
Details | Diff | Splinter Review

Description Michał 2011-09-13 09:23:19 PDT
Created attachment 559968 [details]
Screenshot

This Bug happened when I was using PhpMyAdmin (works on every version).
If text in Alert (JS: alert()) is very, very long, it can go out of the screen.
In that case, you won't be able to see OK Button.
Comment 1 Michał 2011-09-13 09:24:18 PDT
Created attachment 559970 [details]
TestCase
Comment 2 Matthias Versen [:Matti] 2011-09-13 10:15:19 PDT
wfm with Mozilla/5.0 (Windows NT 6.1; rv:9.0a1) Gecko/20110912 Firefox/9.0a1 SeaMonkey/2.6a1
Comment 3 Michał 2011-09-13 10:26:55 PDT
I have tried on the same version of Nightly as you did, but bug is still present.
When I have runed fresh profile for the first time, it showed in normal way, but after the next reload it showed up just like on the Screenshot.

Maybe it's somehow connected with my Screen Resolution (I'm using 1920x1080), my Windows font-size is set to 125%. Generaly I'm using Firefox Maximized.
Comment 4 Tim (fmdeveloper) 2011-09-13 20:03:20 PDT
Able to reproduce on Mozilla/5.0 (Windows NT 5.1; rv:9.0a1) Gecko/20110913 Firefox/9.0a1 ID:20110913030846 with resolution set to 1920 x 1200 - no change in font size in my setup
Comment 5 Matthias Versen [:Matti] 2011-09-18 10:59:42 PDT
marking new based on comment#4
Comment 6 Brian R. Bondy [:bbondy] 2011-09-18 15:50:07 PDT
Works for me in Firefox Release (6.0)
I can reproduce the problem in all of Firefox Beta (7.0), Aurora (8.0), and Nightly (9.0)
Comment 7 Matthias Versen [:Matti] 2011-09-18 16:09:35 PDT
This works in Seamonkey but fails in Firefox

Last good nightly: 2011-07-01
First bad nightly: 2011-07-02

Pushlog:
<http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=beceddeee3f4&tochan
ge=549e3276ed25>
Comment 8 Brian R. Bondy [:bbondy] 2011-09-18 16:13:18 PDT
Just found the same :)
Comment 9 Matthias Versen [:Matti] 2011-09-18 16:19:16 PDT
Just a guess; Could this be either the checkin from Ddao or smaug ?
Comment 10 Brian R. Bondy [:bbondy] 2011-09-18 16:20:29 PDT
I think it's probably Kai's in Bug 431078.  I'll verify this shortly.
Comment 11 Brian R. Bondy [:bbondy] 2011-09-18 16:22:38 PDT
I just seen the one in Windows widget without reading the commit messages :)
Sorry you're probably right about Bug 668500, will check shortly.
Comment 12 Brian R. Bondy [:bbondy] 2011-09-18 16:33:08 PDT
Confirmed that the regression was introduced in:
Bug 668500 - Scrollbars appear if the notificationbox overflows

We may want to backout changeset http://hg.mozilla.org/mozilla-central/rev/4a10fb9c4b34 before this hits release on September 27th?
Comment 13 Dão Gottwald [:dao] 2011-09-19 04:32:18 PDT
The tab-modal alert implementation seems to assume that it's in a container (e.g. <notificationbox>) that overflows in a special way.
Comment 14 Dão Gottwald [:dao] 2011-09-19 05:57:00 PDT
Created attachment 560882 [details] [diff] [review]
patch

The dependency on <notificationbox> is even more explicit than I expected it to be.
Comment 15 Dão Gottwald [:dao] 2011-09-27 11:20:13 PDT
*** Bug 689503 has been marked as a duplicate of this bug. ***
Comment 16 Justin Dolske [:Dolske] 2011-09-30 16:57:35 PDT
Comment on attachment 560882 [details] [diff] [review]
patch

Review of attachment 560882 [details] [diff] [review]:
-----------------------------------------------------------------

Hmm. So the fix to bug 668500 caused this to break?

I noticed one interesting quirk on trunk with the testcases I wrote for bug 613749 (which implemented the support for limiting the prompt's size)... With the "Wordy" and "XtraWordy" testcases the line breaks -- once -- and the prompt overflows at small enough window sizes. [And snaps to the correct size as soon as you resize the window.] But even with a super-narrow window, the line only breaks once. I'm not sure I understand why it fails that way, do you?

I also noticed some glitchy prompt sizing when resizing on some of the above tests (like it will bounce between showing 2 lines + 1 scrollbar and multiple lines with a vertical scrollbar), but it seems to be doing the same thing on FF6 so it's no worse. Frank, we some of those known from the original landing? I can't remember.
Comment 17 Justin Dolske [:Dolske] 2011-09-30 16:58:13 PDT
Forgot to note: my last paragraph in comment 16 refers to my local build with this patch.
Comment 18 Dão Gottwald [:dao] 2011-10-01 12:39:57 PDT
(In reply to Justin Dolske [:Dolske] from comment #16)
> Comment on attachment 560882 [details] [diff] [review] [diff] [details] [review]
> patch
> 
> Review of attachment 560882 [details] [diff] [review] [diff] [details] [review]:
> -----------------------------------------------------------------
> 
> Hmm. So the fix to bug 668500 caused this to break?
> 
> I noticed one interesting quirk on trunk with the testcases I wrote for bug
> 613749 (which implemented the support for limiting the prompt's size)...
> With the "Wordy" and "XtraWordy" testcases the line breaks -- once -- and
> the prompt overflows at small enough window sizes. [And snaps to the correct
> size as soon as you resize the window.] But even with a super-narrow window,
> the line only breaks once. I'm not sure I understand why it fails that way,
> do you?

This is due to the 60% width cap in the onResize method. What's 100% depends on the unwrapped string.
Comment 19 Marco Bonardo [::mak] (Away 6-20 Aug) 2011-10-03 07:57:52 PDT
https://hg.mozilla.org/mozilla-central/rev/c2931c64df06
Comment 20 Asa Dotzler [:asa] 2011-10-03 14:47:21 PDT
Comment on attachment 560882 [details] [diff] [review]
patch

release drivers are concerned about taking this into Beta. It's shipped as a regression in 7 and we're not seeing feedback that major sites or intranets are broken by this. absent that feedback, it's hard to justify taking this into Beta.
Comment 22 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2011-10-04 11:35:49 PDT
word-wrap:break-word might have been useful here.
Comment 23 christian 2011-10-10 10:43:17 PDT
Comment on attachment 560882 [details] [diff] [review]
patch

Denied for beta.
Comment 24 Mihaela Velimiroviciu (:mihaelav) 2011-11-18 07:47:32 PST
Mozilla/5.0 (Windows NT 6.1; rv:9.0) Gecko/20100101 Firefox/9.0
Mozilla/5.0 (Windows NT 6.1; rv:10.0a2) Gecko/20111116 Firefox/10.0a2
Mozilla/5.0 (Windows NT 6.1; rv:11.0a1) Gecko/20111116 Firefox/11.0a1

Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:9.0) Gecko/20100101 Firefox/9.0
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:10.0a2) Gecko/20111116 Firefox/10.0a2
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:11.0a1) Gecko/20111117 Firefox/11.0a1

Mozilla/5.0 (Windows NT 5.1; rv:9.0) Gecko/20100101 Firefox/9.0
Mozilla/5.0 (Windows NT 5.1; rv:10.0a2) Gecko/20111110 Firefox/10.0a2
Mozilla/5.0 (Windows NT 5.1; rv:11.0a1) Gecko/20111110 Firefox/11.0a1

Mozilla/5.0 (X11; Linux x86_64; rv:9.0) Gecko/20100101 Firefox/9.0
Mozilla/5.0 (X11; Linux x86_64; rv:10.0a2) Gecko/20111117 Firefox/10.0a2
Mozilla/5.0 (X11; Linux x86_64; rv:11.0a1) Gecko/20111117 Firefox/11.0a1

Verified using teh testcase from comment #1 and no overlap was observed

Note You need to log in before you can comment on or make changes to this bug.