Bug 12919 fixed: Rotation on plots was disabled after using menus 13/12613/2
Calixte DENIZET [Fri, 20 Sep 2013 08:21:47 +0000 (10:21 +0200)]
Change-Id: I2ac2aae36b388f24526b0d1c7f5c9c4b1be13659

scilab/CHANGES_5.5.X
scilab/modules/renderer/src/java/org/scilab/modules/renderer/JoGLView/interaction/DragZoomRotateInteraction.java

index 906668c..3aeda6b 100644 (file)
@@ -728,4 +728,7 @@ Bug Fixes
 
 * Bug #12916 fixed - power help page improved.
 
+* Bug #12919 fixed - Rotation on plots was disabled after using menus.
+
 * Bug #12927 fixed - ones function could not take integer type input.
+
index a280988..247132c 100644 (file)
@@ -103,7 +103,10 @@ public class DragZoomRotateInteraction extends FigureInteraction {
 
         @Override
         public void mouseReleased(MouseEvent e) {
-            pressedButtons--;
+            if (pressedButtons > 0) {
+                pressedButtons--;
+            }
+
             if (pressedButtons == 0) {
                 getDrawerVisitor().getComponent().removeMouseMotionListener(mouseMotionListener);
                 currentAxes = null;