Working on render logic

This commit is contained in:
Robert committed 2019-10-23 17:35:13 +02:00
1 parent c2c849201d
commit 9badc666e8
8 files changed
+50 -19

No files matched your search

@@ -63,8 +63,8 @@ namespace Artemis.UI.ViewModels.Controls.SurfaceEditor
{
var roundedX = Math.Round((mousePosition.X + _dragOffsetX) / 10, 0, MidpointRounding.AwayFromZero) * 10;
var roundedY = Math.Round((mousePosition.Y + _dragOffsetY) / 10, 0, MidpointRounding.AwayFromZero) * 10;
X = roundedX;
Y = roundedY;
X = Math.Max(0, roundedX);
Y = Math.Max(0, roundedY);
}
// ReSharper disable once UnusedMember.Global - Called from view