mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Fix float equality warning in Rectangle::enlargeIfAdjacent()
Co-authored-by: Tobias Hienzsch <post@tobias-hienzsch.de>
This commit is contained in:
parent
7626f86607
commit
c9c2ca0aab
1 changed files with 2 additions and 2 deletions
|
|
@ -741,7 +741,7 @@ public:
|
|||
*/
|
||||
bool enlargeIfAdjacent (Rectangle other) noexcept
|
||||
{
|
||||
if (pos.x == other.pos.x && getRight() == other.getRight()
|
||||
if (exactlyEqual (pos.x, other.pos.x) && exactlyEqual (getRight(), other.getRight())
|
||||
&& (other.getBottom() >= pos.y && other.pos.y <= getBottom()))
|
||||
{
|
||||
auto newY = jmin (pos.y, other.pos.y);
|
||||
|
|
@ -750,7 +750,7 @@ public:
|
|||
return true;
|
||||
}
|
||||
|
||||
if (pos.y == other.pos.y && getBottom() == other.getBottom()
|
||||
if (exactlyEqual (pos.y, other.pos.y) && exactlyEqual (getBottom(), other.getBottom())
|
||||
&& (other.getRight() >= pos.x && other.pos.x <= getRight()))
|
||||
{
|
||||
auto newX = jmin (pos.x, other.pos.x);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue