摘要: 今天有个需求要判断当前鼠标左键是否被按下,因为只有在此时才需要做一些特别的逻辑使代码运行正常,来完成正确的workflow。google了一下,还是在stackoverflow上找到一篇靠谱的文章,原文链接猛点此处。总结一下如下:jQuery中的行为:在mouse move事件中,查看当前鼠标左键、中键、右键状态时的情况:no button pressed: e.which = 1 e.button = 0left button pressed: e.which = 1 e.button = 0middle button pressed: e.which = 2 e.button = 1rig 阅读全文
posted @ 2012-10-29 15:46 zsheng823 阅读(1190) 评论(0) 推荐(0) 编辑