Question onmouseup Not Fired if Mouse Moves After onmousedown

njsokalski

Well-known member
Joined
Mar 16, 2011
Messages
102
Programming Experience
5-10
I have a page in which an image is displayed while the user has the mouse button down, and is then hidden when the button is released. However, if the user presses the mouse button, moves the mouse (even just a tiny bit, still within the same element), and the releases the mouse button, the onmouseup event is not triggered. Therefore, the image does not get hidden because JavaScript is not detecting the release of the mouse button. Why is it doing this, and what can I do about it? I am currently using Internet Explorer 9 on Windows 7. Any help would be appreciated. Thanks.
 
Back
Top