VivaGraphJS icon indicating copy to clipboard operation
VivaGraphJS copied to clipboard

Zoom In Zoom out feature

Open sherlholmes opened this issue 13 years ago • 4 comments
trafficstars

Zoom in zoom out feature using mouse wheel is not working on Internet explorer.

sherlholmes avatar Aug 18 '12 11:08 sherlholmes

Which version of IE? What kind of graphics are you using (SVG or CSS)?

anvaka avatar Aug 18 '12 16:08 anvaka

In IE9, I am Using SVG graphics. Is there any way to have simple slider for zooming?

sherlholmes avatar Aug 18 '12 17:08 sherlholmes

Has there been an update to this?

taichatha avatar Oct 17 '16 20:10 taichatha

IE used to be special but like with many other things MS gave up on being special. So to make zooming with the mouswheel work in IE11 the updateScrollEvents function in vivagraph needs to be modified just a little bit. Basically remove the 'special' treatment for IE and use the 'mousewheel' event for all browsers.

REPLACE BOLD TEXT WITH 'mousewheel' or just get rid of the if/else statement all together. Hope this helps.

if (browserInfo.browser === 'webkit') { element.addEventListener('mousewheel', handleMouseWheel, false); // Chrome/Safari } else { element.addEventListener('DOMMouseScroll', handleMouseWheel, false); // Others }

pbless avatar Mar 16 '17 02:03 pbless