[thelist] Javascript/mozilla mouseup event weirdness

Courtenay court3nay at gmail.com
Wed Oct 20 10:17:37 CDT 2004


I'm doing a drag-n-drop operation by using onclick, onmousemove and onmouseup.
The user can 'trash' an image by dragging it out of its container div.
(the image is removed with removeChild)  If the container div is then
empty, it is also removed from the page.

Here's the problem: when you remove the container, mozilla decides
that you are, in fact, dragging, and starts highlighting text.  Any
ideas on stopping the event propagation?
(this does not occur in IE, and does not occur when you remove the
dragged image)

I can post code if it helps, but I'm sure there's a one-line solution.
 I think the key is, that because there's no current event to work
with, mozilla kinda jumps up a level, and assumes you've been trying
to hilight text.. how would I break out of the event cycle?

TIA


More information about the thelist mailing list