Allow moving away though the top left corner.

This commit is contained in:
kenkeiras 2018-01-20 22:09:25 +01:00
parent f821f49b94
commit f464902399

View File

@ -306,8 +306,8 @@ class CanvasView extends View implements PartGrid {
int yMovement = _mouseDownPoint.item2 - yInScreen; int yMovement = _mouseDownPoint.item2 - yInScreen;
_viewOrigin = new Tuple2( _viewOrigin = new Tuple2(
Math.max(_viewOrigin.item1 + xMovement, 0), _viewOrigin.item1 + xMovement,
Math.max(_viewOrigin.item2 + yMovement, 0)); _viewOrigin.item2 + yMovement);
_mouseDownPoint = new Tuple2(xInScreen, yInScreen); _mouseDownPoint = new Tuple2(xInScreen, yInScreen);
} }
else { else {