1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Added new method Rectangle::toNearestIntEdges(), and used this to improve the Grid layout snapping

This commit is contained in:
jules 2018-04-04 16:43:17 +01:00
parent 5c8084c3e6
commit 121719be69
2 changed files with 15 additions and 4 deletions

View file

@ -1017,7 +1017,7 @@ void Grid::performLayout (juce::Rectangle<int> targetArea)
+ targetArea.toFloat().getPosition();
if (auto* c = item->associatedComponent)
c->setBounds (item->currentBounds.toNearestInt());
c->setBounds (item->currentBounds.toNearestIntEdges());
}
}