piccolo2d / piccolo2d.java

Structured 2D Graphics Framework
http://piccolo2d.org
Other
51 stars 14 forks source link

MouseWheelZoomEventHandler doesnt stop zooming #257

Closed mro closed 8 months ago

mro commented 9 years ago

Originally reported on Google Code with ID 257

What steps will reproduce the problem? What is the expected output? What do you see
instead?
Using a mouseWheelRotated/ mouseWheelZoomEventHandler causes the panel/scrollpane/swing/canvas
to be zoomed very deep. The reason being is that it doesnt stop zooming after stopping
to rotate the mouse wheel. Instead it keeps zooming until the x value is NaN.

What version of the product are you using? On what operating system?
Piccolo2D 3.0 on Xubuntu

I used following code to add a mouse wheel zoom event handler:

canvas.removeInputEventListener(canvas.getZoomEventHandler());

final PMouseWheelZoomEventHandler mouseWheelZoomEventHandler = new PMouseWheelZoomEventHandler();
canvas.addInputEventListener(mouseWheelZoomEventHandler);

Reported by osto_dani@hotmail.com on 2014-02-16 22:12:23

mro commented 9 years ago
Thank you for reporting this issue.  Might you be able to check if the MouseWheelZoomExample
works for you?

http://code.google.com/p/piccolo2d/source/browse/piccolo2d.java/trunk/examples/src/main/java/org/piccolo2d/examples/MouseWheelZoomExample.java

Reported by heuermh on 2014-02-17 01:40:23