Bug Tracker

Modify

Ticket #1564 (closed bug: wontfix)

Opened 6 years ago

Last modified 6 years ago

scroll event error in firefox

Reported by: bigqiang Owned by:
Priority: major Milestone: 1.2.2
Component: event Version: 1.1.4
Keywords: scroll Cc:
Blocking: Blocked by:

Description

Doing $("body").scroll() doesnt raise the event specified in the onscroll attribute in firefox.

Attachments

1564.diff Download (620 bytes) - added by davidserduke 6 years ago.
possible patch

Change History

comment:1 Changed 6 years ago by davidserduke

  • need changed from Patch to Review
  • Status changed from new to closed
  • Resolution set to wontfix
  • Milestone changed from 1.2 to 1.2.2

While this does appear to be true, if you look at the official documentation here:

 http://docs.jquery.com/Events

You'll see .scroll() as a trigger is not supported. That said, I would fix it if it was an easy fix but it appears in FireFox (and Safari doesn't work so perhaps there too or some other problem) the onscroll is set as an attribute without a property. So when the code checks for the onscroll property it doesn't exist. The fix would be to use getAttribute() (plus much research and testing) and at this point I don't see a compelling argument to make the change.

If you disagree you can reopen the bug with your thoughts.

Changed 6 years ago by davidserduke

possible patch

comment:2 Changed 6 years ago by davidserduke

BTW, just in case someone decides to fix it, while I was looking in to the bug I found a possible fix in .trigger() and have attached it as a possible patch. It is not thoroughly tested by any means.

Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.

View

Add a comment

Modify Ticket

Action
as closed
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.