Closed Bug 633160 Opened 13 years ago Closed 13 years ago

move away from the page by file drop is possible in spite of modal file picker dialog

Categories

(Core :: Widget: Win32, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla9
Tracking Status
blocking2.0 --- -

People

(Reporter: kuno.meyer, Assigned: bbondy)

References

()

Details

(Keywords: regression)

Attachments

(1 file, 3 obsolete files)

User-Agent:       Mozilla/5.0 (Windows NT 5.1; rv:2.0b11) Gecko/20100101 Firefox/4.0b11
Build Identifier: Mozilla/5.0 (Windows NT 5.1; rv:2.0b11) Gecko/20100101 Firefox/4.0b11

It is possible to move away from a web page by "file drop" even if that page has a modal file picker dialog open. This seems inconsistent, since FF otherwise enforces the modality of the dialog and even prevents tab switching.

Reproducible: Always

Steps to Reproduce:
1. Go to a web page with a file picker (e.g. http://www.freepdfconvert.com/)
2. Open the file picker by clicking on "browse" --> a modal dialog appears
3. Drag a local file into the web page area in the background of the modal picker dialog, drop it there.
Actual Results:  
The file content gets loaded into the browser. The old page is gone.

Expected Results:  
File dropping should not be possible while the file picker is open.
Regression window(cached m-c hourly):
Works:
http://hg.mozilla.org/mozilla-central/rev/522df66198cf
Mozilla/5.0 (Windows; U; Windows NT 6.1; WOW64; en-US; rv:1.9.3a6pre) Gecko/20100624 Minefield/3.7a6pre ID:20100624185700
Fails:
http://hg.mozilla.org/mozilla-central/rev/51bd519736c4
Mozilla/5.0 (Windows; U; Windows NT 6.1; WOW64; en-US; rv:1.9.3a6pre) Gecko/20100624 Minefield/3.7a6pre ID:20100624221810
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=522df66198cf&tochange=51bd519736c4
Blocks: 513162
Status: UNCONFIRMED → NEW
blocking2.0: --- → ?
Component: Drag and Drop → Widget: Win32
Ever confirmed: true
Keywords: regression
QA Contact: drag-drop → win32
Version: unspecified → Trunk
This is a regression but I don't think it's worth blocking on.
blocking2.0: ? → -
Assignee: nobody → netzen
Depends on: 357601
Adding a depends on Bug 357601 not because the regression was introduced there (that's not even pushed yet), but because the fix I made is based on code in my patch queue that is in Bug 357601.
Comment on attachment 551485 [details] [diff] [review]
Patch for file picker's parent accepts drops in spite of file picker being modal.

Might want to use mWindow->IsEnabled instead.
Implemented review comments.
Attachment #551485 - Attachment is obsolete: true
Attachment #551624 - Flags: review?(neil)
Attachment #551485 - Flags: review?(neil)
Comment on attachment 551624 [details] [diff] [review]
Patch for file picker's parent accepts drops in spite of file picker being modal.

>+  nsWindow * wnd = static_cast<nsWindow *>(mWindow);
I said mWindow->IsEnabled; no need to cast! r=me with that fixed.
Attachment #551624 - Attachment is obsolete: true
Attachment #552575 - Flags: review?(neil)
Attachment #551624 - Flags: review?(neil)
Attachment #552575 - Flags: review?(neil) → review+
Blocks: 573321
This was pushed to try, results in progress:
http://tbpl.allizom.org/?tree=Try&usebuildbot=1&rev=cde44aaad760
http://hg.mozilla.org/mozilla-central/rev/191f7bab5f5a
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla9
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: