mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Better CalloutBox positioning.
This commit is contained in:
parent
41545be958
commit
aa9241a14a
1 changed files with 1 additions and 1 deletions
|
|
@ -195,7 +195,7 @@ void CallOutBox::updatePosition (const Rectangle<int>& newAreaToPointTo, const R
|
|||
const Point<float> centre (constrainedLine.findNearestPointTo (targetCentre));
|
||||
float distanceFromCentre = centre.getDistanceFrom (targets[i]);
|
||||
|
||||
if (! (centrePointArea.contains (lines[i].getStart()) || centrePointArea.contains (lines[i].getEnd())))
|
||||
if (! centrePointArea.intersects (lines[i]))
|
||||
distanceFromCentre += 1000.0f;
|
||||
|
||||
if (distanceFromCentre < nearest)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue