左键单击 wdContextMenu
web-delicious 有一个很好的分层上下文菜单 jQuery 插件: wdContextMenu。我也想在左键单击上使用它,但我不知道如何执行此操作(没有按钮或代码中的所有绑定、单击和输出方法似乎都可以执行其他操作)。 也许以前有人这样做过。
There is a nice hierarchical jQuery PlugIn for context-menus from web-delicious: wdContextMenu. I want to use it on left clicks too, but I can't figure out how to do this (no button or which in the code, all bind-, click- and out-methods seem to do sth else).
Perhaps someone has done this before.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您需要将行更改
为:
You need to change the line:
to
经过快速演练后,我认为这是不可能实现的,因为
该插件使用 oncontextmenu 事件,在构建菜单组件的过程中,单击事件(用于左键单击)被覆盖,以使元素始终返回 false。
After a quick walkthrough I don't think this is achievable because
this plugin uses oncontextmenu event and in the process of building up the menu component the click event(which is for the left click) is overridden for the elements to return false always.