Events bubble up so you'll be able to catch the event and figure out which button it originated from.
事件冒泡了等,这样您就能够捕获事件,并找出它来自哪个按钮。
If you say "you know" too much, wear a golf counter on your wrist, and press the button whenever you catch yourself saying "you know".
如果你总是把“youknow”挂在嘴边,就在手腕上戴个高尔夫计数器,每当意识到自己说一次“youknow”时就按一下计数键。
So the UI test automation will not catch the logic error if the application has the wrong method wired to a button click event (although every test would fail and you'd find the problem quickly).
所以如果应用程序为按钮单击事件关联了错误的方法,UI测试自动化不会捕捉到逻辑错误(虽然每次测试都会失败,而且您会很快发现问题)。
An alternative is to use onmouseup to catch any mouse release and check for the right button.
作为代替可以使用onmouseup事件来检测和处理松开鼠标右键的事件。
An alternative is to use onmouseup to catch any mouse release and check for the right button.
作为代替可以使用onmouseup事件来检测和处理松开鼠标右键的事件。
应用推荐