开发者

what is the difference between onClick and mouseClick?

开发者 https://www.devze.com 2022-12-11 01:14 出处:网络
wondering what is the major difference between these two: 开发者_运维百科onClick and mouseClick..Looks like you are confusing Java with Javascript. There is not onClick() method on Java APIs.Assuming

wondering what is the major difference between these two: 开发者_运维百科onClick and mouseClick..


Looks like you are confusing Java with Javascript. There is not onClick() method on Java APIs.


Assuming that you're talking about Java, the difference is right there in the documentation for MouseEvent:

Mouse Events

* a mouse button is pressed
* a mouse button is released
* a mouse button is clicked (pressed and released)
* the mouse cursor enters the unobscured part of component's geometry
* the mouse cursor exits the unobscured part of component's geometry

If you're talking about JavaScript, I'm going to assume that it's the difference between old style and new style event handling. But I've only ever used onClick, so can't give a definitive answer.

0

精彩评论

暂无评论...
验证码 换一张
取 消