使用jTopo给Html5 Canva中绘制的元素添加鼠标事件_html5教程技巧
来源:互联网 发布:软件图标素材下载 编辑:程序博客网 时间:2024/05/21 10:22
var node = new JTopo.Node("Hello");
node.setLocation(409, 269);
node.mousedown(function(event){
if(event.button == 2){
node.text = '按下右键';
}else if(event.button == 1){
node.text = '按下中键';
}else if(event.button == 0){
node.text = '按下左键';
}
});
node.mouseup(function(event){
if(event.button == 2){
node.text = '松开右键';
}else if(event.button == 1){
node.text = '松开中键';
}else if(event.button == 0){
node.text = '松开左键';
}
});
node.click(function(event){
console.log("单击");
});
node.dbclick(function(event){
console.log("双击");
});
node.mousedrag(function(event){
console.log("拖拽");
});
node.mouseover(function(event){
console.log("mouseover");
});
node.mousemove(function(event){
console.log("mousemove");
});
node.mouseout(function(event){
console.log("mouseout");
});
0 0
- 使用jTopo给Html5 Canva中绘制的元素添加鼠标事件_html5教程技巧
- 使用jTopo给Html5 Canva中的元素添加鼠标事件
- HTML5 input元素类型:email及url介绍_html5教程技巧
- 给ajax加载的页面元素添加鼠标事件
- 用HTML5 实现橡皮擦的涂抹效果的教程_html5教程技巧
- HTML5全屏(Fullscreen)API详细介绍_html5教程技巧
- html5 svg 中元素点击事件添加
- 使用js给元素添加事件
- 给动态增加的元素添加事件
- 给动态添加的元素绑定事件
- 给DataGridView 添加鼠标单击事件,并且在contexMenutstrip中显示,获取该行的主键
- html5 svg 中元素点击事件添加方法
- 给Jquery动态添加的元素添加事件
- 给Jquery动态添加的元素添加事件
- 给Jquery动态添加的元素添加事件
- 给Jquery动态添加的元素添加事件
- JS给元素添加事件
- 用 HTML5 给 iPad,iPhone 打造速度超快的应用_HTML5研究小组
- WireShark抓包后统计
- poj 3160 Father Christmas flymouse (SCC缩点+SPFA求最长路)
- C++常用计算几何算法
- SPDL: SHGetSpecialFolderLocation()、SHGetFileInfo()、SHGetPathFromIDList()函数
- Android View的刷新机制
- 使用jTopo给Html5 Canva中绘制的元素添加鼠标事件_html5教程技巧
- 通过VMware Fusion将 Mac 中的文件夹共享到虚拟机
- javaweb JDBC 数据库连接mysql 配置代码 (直接可用)
- jQuery注意事项及技巧
- 关于坐标系
- #笔记#圣思园 JavaWeb 第12讲——JSP基础知识、语法、内置对象、表单、客户机交互
- DrawerLayout控件的使用
- 那些不为人知的CSS3
- 细数iOS上那些你绝对不会注意到的神细节