1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-13 00:04:19 +00:00

Fixed a rounding error in Component::isMouseOver

This commit is contained in:
ed 2017-11-17 16:22:48 +00:00
parent 370cf229c6
commit e8518048b4

View file

@ -2960,7 +2960,7 @@ bool Component::isMouseOver (const bool includeChildren) const
auto* c = ms.getComponentUnderMouse();
if ((c == this || (includeChildren && isParentOf (c)))
&& c->reallyContains (c->getLocalPoint (nullptr, ms.getScreenPosition()).roundToInt(), false)
&& c->reallyContains (c->getLocalPoint (nullptr, ms.getScreenPosition().roundToInt()), false)
&& ((! ms.isTouch()) || ms.isDragging()))
return true;
}