public void onMouseMove(MapViewWindow mapView, Location loc, Point ab) { if (strategy == null) { ResizingStrategy s = ResizingStrategies.getStrategy(rect, ab); if (s != null) { Cursor.Current = s.cursor; } } else { _rect = strategy.resize(_rect, ab); Cursor.Current = strategy.cursor; World.world.onAllVoxelUpdated(); } }
public void onClick(MapViewWindow mapView, Location loc, Point ab) { if (strategy == null) { strategy = ResizingStrategies.getStrategy(rect, ab); if (strategy == null) { // mouse is out of place. _rect = new Rectangle(ab, new Size(1, 1)); strategy = ResizingStrategies.SE; } } else { strategy = null; } World.world.onAllVoxelUpdated(); }