研习DOM中的事件方法,发现一些细微差别,百度一下没有类似的解答,随手记下来。

onmousewheel事件 

以下摘自http://help.dottoro.com/ljmracjb.php

Browser support:

IE,火狐,opera,sarafi,chrome

Occurs when the mouse wheel rolls.
In Firefox, use the DOMMouseScroll event and the detail event property instead.

Note: the onmousewheel and DOMMouseScroll events are also fired on elements that have no scrollbar or when the contents are not scrolled. If you would like to receive a notification when the contents of an element are scrolled, use the onscroll event.

 
翻译:该事件发生在鼠标滚轮滚动时,火狐中,使用DOMMouseScroll跟其细节事件(参看http://help.dottoro.com/ljrxdxdw.php及http://www.feiesoft.com/html/events/onmousewheel.html)代替。注意:onmousewheel和DOMMouseScroll事件,在没有滚动条或者内容没有被滚动的时候也会发生,意思是只要鼠标动不管页面动不动。如果你是想一个元素内容滚动后接受一个通知的话,使用onscroll事件。
 
onscroll事件
 

Browser support:

IE,火狐,opera,sarafi,chrome
Occurs when the contents of an element have been scrolled.
This event is only fired on elements that have a scrollbar. Use the overflow style property to create scrollbars for an element.
 
翻译:事件发生在元素内容滚动的时候,也包括键盘上下键,载入也可触发。事件仅仅在有滚动条时发生,使用overflow属性为元素创建一个滚动条。
 
ok,就这样。
 

最新文章

  1. T-SQL删除重复数据
  2. 如何使用mybatis《三》
  3. table 操作
  4. Git 在小团队中的管理流程(转)
  5. 【转】JDBC学习笔记(4)——PreparedStatement的使用
  6. 在 iOS 10.0 之后, App 要调用手机相机与相簿应注意的事项
  7. ES ik分词器使用技巧
  8. HTTP/1.1 请求方法
  9. js实现简易版validate
  10. SharePoint Framework解决方案管理参考(一)
  11. Netty实战五之ByteBuf
  12. Python 中if __name__ == '__main__': 的作用和原理
  13. [iOS]改变UIAlertController的标题、内容的字体和颜色
  14. 搭建基于IDEA+Selenium+Java+TestNG+Maven+Jenkins+SVN的Web端UI自动化测试环境
  15. selenium +chromdriver模块
  16. 7.ViewPagerIndicator
  17. vi常用命令总结
  18. Vue插件写、用详解(附demo)
  19. HDU 4366 Successor(dfs序 + 分块)题解
  20. MySQL on Linux 部署手册

热门文章

  1. IOS开发基础知识--碎片36
  2. 一个3D ar打飞机的游戏iOS源码
  3. 在UTF-8中,一个汉字为什么需要三个字节?
  4. ORACLE动态采样分析
  5. fdisk添加分区引起的Linux Error: 22: Invalid argument
  6. C#--属性详解
  7. DbVisualizer连接hbase
  8. x01.TextProc: 两三分钟完成的一个小工具
  9. CentOS 7安装JDK
  10. 【Windows编程】系列第二篇:Windows SDK创建基本控件