HTML5 SVG 和鼠标事件
我用 Inkscape 制作了一些六边形并将它们放置在一些 HTML5 中。我让 onmouseover 事件起作用,但 onmouseout 事件不起作用。我在 Google Chrome 11.0.696.57 beta 上运行它。有谁知道问题是什么?
I made a few hexagons with Inkscape and placed them in some HTML5. I got the onmouseover event to work but the onmouseout event does not work. I'm running this on Google Chrome 11.0.696.57 beta. Does anyone know what the problem is?
Here is link to HTML
https://docs.google.com/leaf?id=0B7ZCkMUvddWIOTAxNmJlYjctODNlOS00MzFlLTgwY2EtOTY1NzZkZGQ2Yjgx&sort=name&layout=list&num=50
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我在示例中更改了一些内容以在 chrome 中修复它(该示例在 safari、opera 或 IE9 中不起作用)。
首先,在 onmouseover 和 onmouseout 语句之后有一些分号。
其次,事件正在触发,但 alpha 为 0.06 我将其更改为 0.6,现在它正在触发更加明显:
http://jsfiddle.net/ERyS4/7/
I have changed a few thing in the example to fix it in chrome (the example dosen't work in safari, opera or IE9).
Firstly you had some semi colons after the onmouseover and onmouseout statements.
Secondly the event was firing but the alpha was 0.06 I changed it to 0.6 and now it is much more obvious that it is firing:
http://jsfiddle.net/ERyS4/7/