How do I suppress window mouse wheel scrolling…?
问题 I'm working on a canvas app embedded in a page. I have it so you can zoom into the drawing with the mousewheel but unfortunately this scrolls the page as it is part of an article. Is it possible to prevent mousewheel scrolling on the window when I'm mousewheeling on a dom element?! 回答1: Attach an event handler for mousewheel (Not Gecko) / DOMMouseScroll (Not IE) and prevent its default action (that is to scroll content): if (element.addEventListener) element.addEventListener("DOMMouseScroll",