onDrag handler in FireFox?

T

tfrancis

Hi,

I am trying to handle my mouse movements myself in my JavaScript
application which is ok except for the following problem.

If I happen to click on an image and then move the mouse, the "no-drop"
icon appears as the browser is starting to drage the image url
somewhere. When this happens, I no longer recieve any mouse events in
my JS app. This can be prevented in IE by adding an event handler for
the onDrag event that simply returns false. This prevents IE from
continuing to try and drag the image and instead it continues to send
mouse events.

However, I cannot find a way to do this in Firefox. Can anyone help?

Cheers,

Tom...
 
M

Martin Honnen

This can be prevented in IE by adding an event handler for
the onDrag event that simply returns false. This prevents IE from
continuing to try and drag the image and instead it continues to send
mouse events.

However, I cannot find a way to do this in Firefox.

<img onmousedown="if (event.preventDefault) {
event.preventDefault();
}"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,767
Messages
2,569,572
Members
45,046
Latest member
Gavizuho

Latest Threads

Top