为 SVG 元素设置 OnClickListener
假设我有一个 SVG 元素,如下所示。如何添加 onClickListener?
solved, see below.
Say I have an SVG element, as follows. How do I add an onClickListener?
solved, see below.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我猜你指的是
FieldChangeListener
而不是OnClickListener
(错误的平台;)。SVGImage
不是 RIM 开发的对象的一部分,因此遗憾的是您无法这样做。任何能够拥有FieldChangeListner
的东西都必须是net.rim.device.api.ui.Field
类的子类。I'm going to guess you're meaning a
FieldChangeListener
rather than anOnClickListener
(wrong platform ;).SVGImage
isn't part of the RIM-developed objects, so unfortunately you won't be able to. Anything that is going to be able to have aFieldChangeListner
has to be a subclass of thenet.rim.device.api.ui.Field
class.以防万一有人对它是如何完成的感兴趣......
Just in case someone's interested in how it's done...