Refactor isQuadInBounds

This commit is contained in:
Leon Gebler 2021-02-23 00:25:40 +01:00
parent 71b30bdbbb
commit 2a4139a207
1 changed files with 3 additions and 5 deletions

View File

@ -242,12 +242,10 @@ private bool scaleHitObjects(OsuHitObject[] hitObjects, Anchor reference, Vector
private (bool X, bool Y) isQuadInBounds(Quad quad)
{
(bool X, bool Y) result;
bool xInBounds = (quad.TopLeft.X >= 0) && (quad.BottomRight.X < DrawWidth);
bool yInBounds = (quad.TopLeft.Y >= 0) && (quad.BottomRight.Y < DrawHeight);
result.X = (quad.TopLeft.X >= 0) && (quad.BottomRight.X < DrawWidth);
result.Y = (quad.TopLeft.Y >= 0) && (quad.BottomRight.Y < DrawHeight);
return result;
return (xInBounds, yInBounds);
}
private void moveSelectionInBounds()