[event] Add `wheel` event #1556

Open
wants to merge 5 commits into
from

Conversation

Projects
None yet
2 participants
@juandopazo
Member

juandopazo commented Jan 14, 2014

This PR modifies the mousewheel and adds a wheel event (basically mousewheel becomes an alias of wheel) that matches the W3C spec.

The wheel event has a deltaY payload that requires some math to get right across browsers. But simulating the event would require to do the math in the reverse order if I wanted to make an assertion over it. Does it make sense to do that or should I not test deltaY?

I'm sending the PR to get some early feedback. I still need to:

  • Figure out why tests fail in Phantomjs
  • Update the User Guide
  • Add manual test
  • Test in older browsers
@triptych

This comment has been minimized.

Show comment
Hide comment
@triptych

triptych Jun 3, 2014

Contributor

@juandopazo would this need to be updated/modified if @tilomitra adds Hammer.js ?

Contributor

triptych commented Jun 3, 2014

@juandopazo would this need to be updated/modified if @tilomitra adds Hammer.js ?

@juandopazo

This comment has been minimized.

Show comment
Hide comment
@juandopazo

juandopazo Jun 4, 2014

Member

@triptych I don't think Hammer.js covers the wheel event.

Member

juandopazo commented Jun 4, 2014

@triptych I don't think Hammer.js covers the wheel event.

@triptych

This comment has been minimized.

Show comment
Hide comment
@triptych

triptych Jun 4, 2014

Contributor

Yes, but since the api may change, would that mean you'll need to update this code to be compatible. @juandopazo

Contributor

triptych commented Jun 4, 2014

Yes, but since the api may change, would that mean you'll need to update this code to be compatible. @juandopazo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment