logo
  • 教程列表
  • SO官方文檔
  • 事件
    • 委託活動
    • 附加和分離事件處理程式
    • 文件載入事件 .load()
    • 不使用 ID 重複元素的事件
    • originalEvent
    • 通過 jQuery 開啟和關閉特定事件。 (指定聽眾)
  1. StackOverflow 文件
  2. jQuery 教程
  3. 事件
  4. originalEvent

originalEvent

Created: November-22, 2018

有時會有 jQuery 事件中沒有的屬性。要訪問基礎屬性,請使用 Event.originalEvent

獲取滾動方向

$(document).on("wheel",function(e){
    console.log(e.originalEvent.deltaY)
    // Returns a value between -100 and 100 depending on the direction you are scrolling
})
  • 通過 jQuery 開啟和關閉特定事件。 (指定聽眾)
  • 不使用 ID 重複元素的事件

Copyright © 2018. All right reserved

tastones.com 备案号:鲁ICP备18045372号-1

  • 關於本站
  • 免責聲明