Optimized frame repainting. Fixed mouse click processing.
[sixth-3d.git] / src / main / java / eu / svjatoslav / sixth / e3d / renderer / raster / shapes / basic / solidpolygon / SolidPolygon.java
index 00ae317..e45a991 100644 (file)
@@ -103,10 +103,10 @@ public class SolidPolygon extends AbstractCoordinateShape {
         onScreenPoint3.roundToInteger();
 
         if (mouseInteractionController != null)
-            if (context.mouseClick != null)
-                if (Polygon.pointWithinPolygon(context.mouseClick.coordinate,
+            if (context.mouseEvent != null)
+                if (Polygon.pointWithinPolygon(context.mouseEvent.coordinate,
                         onScreenPoint1, onScreenPoint2, onScreenPoint3))
-                    context.clickedItem = mouseInteractionController;
+                    context.objectUnderMouse = mouseInteractionController;
 
         if (color.isTransparent())
             return;