Closed
Bug 712184
Opened 14 years ago
Closed 12 years ago
Setting a panel as the dragImage with a mouse cursor located inside of the panel breaks drag events on the browser UI
Categories
(Core :: XUL, defect)
Core
XUL
Tracking
()
RESOLVED
FIXED
mozilla29
People
(Reporter: jaws, Assigned: enndeakin)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
|
20.52 KB,
patch
|
Details | Diff | Splinter Review | |
|
1.43 KB,
text/plain
|
Details |
Using the following markup:
> <xul:panel type="drag" allowevents="false" style="pointer-events: none;"><xul:label value="Hello, world!" /></xul:panel>
If I call |event.dataTransfer.setDragImage(panel, 5, 5)|, I am unable to get any drag events on top of the the browser chrome. However, if I change the cursor coordinates {-1, -1}, then the drag events work as expected.
I have attached a patch that reproduces this behavior. To repro, apply the patch, build /browser/base && /browser/themes, then try dragging the bookmark star to the bookmarks toolbar. If the cursor coordinates are changed to {-1, -1}, then the drag item will correctly be dragged to the bookmarks toolbar.
Comment 1•14 years ago
|
||
Neil, this is the drag panel problem that I brought up when attempting to implement tab animations.
| Assignee | ||
Comment 2•14 years ago
|
||
Does it work if you set noautohide="true" ?
If so, then we may just need to adjust nsXULPopupManager::GetVisiblePopups to check IsDragPopup in both loops.
| Reporter | ||
Comment 3•14 years ago
|
||
(In reply to Neil Deakin from comment #2)
> Does it work if you set noautohide="true" ?
Unfornately not. I set noautohide="true" on the panel and changed the call to setDragImage to use the coordinates of {10, 10}, but the cursor is now the "not-allowed" style while dragging the panel.
| Reporter | ||
Comment 4•13 years ago
|
||
Neil, do you think you could help greatwarrior here with fixing this bug?
Assignee: nobody → amod.narvekar
Status: NEW → ASSIGNED
Flags: needinfo?(enndeakin)
Comment 5•13 years ago
|
||
thank you for allowing me to work on this bug. But I am not clear with what exactly the bug is about. Can anyone explain it to me in detail ?
Thanks !
| Assignee | ||
Comment 6•13 years ago
|
||
This is a testcase that shows the behaviour. Dragging the popup should highlight the red boxes in blue when hovering over them.
The bug is that the mouse events are getting sent to blocked to/by the drag feedback image.
Changing the arguments to setDragImage to -20, -20 makes it work as this causes the drag feedback image to be offset from the mouse cursor.
I can help but note that this isn't a simple bug and requires digging into platform specific event handling code.
Flags: needinfo?(enndeakin)
| Reporter | ||
Updated•13 years ago
|
Attachment #730309 -
Attachment mime type: application/vnd.mozilla.xul+xml → text/plain
Comment 7•13 years ago
|
||
I would prefer to keep the assignee to default until i make some significant contribution... I am currently studying the test case. Actually I am not well-versed with XUL.
Assignee: amod.narvekar → nobody
Updated•12 years ago
|
Status: ASSIGNED → NEW
Updated•12 years ago
|
Blocks: fxdesktopbacklog
Whiteboard: p=0
| Assignee | ||
Comment 8•12 years ago
|
||
This should have been fixed by 943759:
Use:
<panel type="drag" mousethrough="always"/>
Updated•12 years ago
|
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•12 years ago
|
Assignee: nobody → enndeakin
Target Milestone: --- → mozilla29
Updated•12 years ago
|
No longer blocks: fxdesktopbacklog
Whiteboard: p=0
You need to log in
before you can comment on or make changes to this bug.
Description
•