javascript - (ADD mousewheel functionality) using DOMmouseScroll AND mousewheel to call functions -
I am trying to create a function that calls another function when the micewheel moves in different directions I have no idea about how to implement it
I basically have the ability to work with the musicwalk program to set up the code, but the Firefox does not support the monthly program is. So there's a way to do this with DOMmouseScroll too. If anyone wants to set it up in the same way I have already set it up.
Note: I'm asking for both domamscroll and mousehelle to use, so I suggest adding my code, but if this can not be done, then it may be okay The way I set the code: I instead re-apply it using cross-browser-compatible events I would suggest In the modern browsers, Mausaskol and Domainscoscos have been boycotted in favor of this new event. Please read all documents on that page for details, as well as cross-browser-compatible $ ('# container') .on ('mousewheel', function (Event) {// crude investigation are supported for viewing events if (typeof event.originalEvent.wheelDeltaX === 'undefined' || typeof event.originalEvent.wheelDeltaY === 'alphabet {Console.log} ("mouse deltas could not be found"); return;} var deltaX = event.originalEvent.wheelDeltaX; var deltaY = event.originalEvent.wheelDeltaY; var scroll lift = deltaax and lieutenant ;; side scroll Right = Deltax> Scroll up = Delta & Lt; 0; var Scroll Down = Deltaa; gt; If (scroll lift) {someFunction} if (scrolled right) {someOtherFunction} if (scroll up) { Anotherfunction} if (scroll down) {and second function}});
addWheelListener function.
Comments
Post a Comment