Jquery1.5的版本小bug
来源:互联网 发布:简单网页源码 编辑:程序博客网 时间:2024/04/28 10:55
event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.
Jquery1.5的版本,没啥逻辑和语法错误,但是浏览器老报这个错,没时间研究,先放这里,回去再仔细查阅。。
原文:http://www.irideas.com/?p=10
由“event.layerX and event.layerY”说起
最近常常在chrome16(360EE5.1)的控制台看到这样的警告
event.layerX and event.layerY are broken and deprecated in WebKit. They will be removed from the engine in the near future.
看着不爽,但这样明白的提示并非不可理解。诱因也是jQuery1.7发布后告知过得
event.layerX and event.layerY: We have removed these non-standard properties in version 1.7. Although we normally would have gone through a deprecation notice period for these, Chrome version 16 generates a flood of console warning messages on the page. Because of this, we decided to remove them immediately. On platforms that still support these properties, they are available through event.originalEvent.layerX and event.originalEvent.layerY.
event.layerX event.layerY 是mozilla特有的,得到鼠标事件发生地相对源元素的偏移,通常是相对于整个document,除非是发生在绝对或相对定位的元素中,则返回相对于该元素的左上方偏移。
W3C规范中是不存在这样的属性,只有clientX/clientY和screenX/screenY是在规范内得(DOM-Level-2-Events)。
- clientX clientY 事件触发时鼠标相对于当前可视窗口的x坐标和y坐标
- screenX screenY 事件触发时鼠标相对于屏幕的x坐标和y坐标
- pageX pageY 事件触发时鼠标在整个document的x坐标和y坐标
- offsetX offsetY 发生事件的地点在触发事件元素的坐标系统中的 x 坐标和 y 坐标
- layerX layerY 发生事件的地点在事件源元素的坐标系统中的x坐标和y坐标
下面是一份广为流传的支持表单
显然layerXY即将在chrome17或之后的版本中退出舞台。
关于这些七七八八的坐标如何使用,有时间再来篇实践吧!
- Jquery1.5的版本小bug
- jQuery1.26以上版本"@"的问题
- Jquery1.6版本后attr的变化
- JQuery1.8的几个小变化
- jQuery1.5的改进细节
- jQuery1.5的改进细节
- PB 9.0.2 7534 版本的小BUG
- Jquery1.6版本后attr的变化,灰常委屈
- jquery1.9,判断浏览器的版本 及类型
- jquery1.9,判断浏览器的版本 及类型
- jquery1.3版本以上使用数组对struts2的兼容性问题
- jQuery1.6以上版本prop和attr的区别
- Jquery1.6版本后attr的变化,灰常委屈
- jQuery1.9.1即其以上版本针对checkbox的调整
- jquery1.9版本,功能改变
- ORACLE的小BUG?
- jacob 的小bug
- 小bug的解决
- MSSQL 数据库同步教程
- JRE JDK是什么?
- 把字符串的所有字符转化为小写
- Linux 文件编码转换
- 黑莓开发资料
- Jquery1.5的版本小bug
- 20120221雨
- 硬件防火墙的开发过程
- 输出摆幅是指
- ubuntu 最简单的rvm ruby rails 安装命令
- linux下的C语言编程(总结篇)
- 基础算法之四--排序: 之插入排序
- RouteData
- 程序员的生存法则