Launcher: improve hit-testing of helipad
Use the other circle only, for hit testing pads in the airport diagram.
This commit is contained in:
parent
f105e8dfb2
commit
dc4201ed9f
2 changed files with 5 additions and 2 deletions
|
@ -107,6 +107,9 @@ AirportDiagram::AirportDiagram(QQuickItem* pr) :
|
|||
m_parkingIconLeftPath.lineTo(16, 16);
|
||||
m_parkingIconLeftPath.lineTo(0, 0);
|
||||
|
||||
m_helipadBoundsPath.moveTo(0, 0);
|
||||
m_helipadBoundsPath.addEllipse(QPointF(0, 0), 16.0, 16.0);
|
||||
|
||||
m_helipadIconPath.moveTo(0,0);
|
||||
m_helipadIconPath.addEllipse(QPointF(0, 0), 16.0, 16.0);
|
||||
m_helipadIconPath.addEllipse(QPointF(0, 0), 13.0, 13.0);
|
||||
|
@ -638,7 +641,7 @@ QPainterPath AirportDiagram::pathForHelipad(const HelipadData& h, const QTransfo
|
|||
{
|
||||
QTransform x = t;
|
||||
x.translate(h.pt.x(), h.pt.y());
|
||||
return x.map(m_helipadIconPath);
|
||||
return x.map(m_helipadBoundsPath);
|
||||
}
|
||||
|
||||
void AirportDiagram::buildTaxiways()
|
||||
|
|
|
@ -142,7 +142,7 @@ private:
|
|||
QuantityValue m_approachDistance;
|
||||
bool m_approachExtensionEnabled = false;
|
||||
|
||||
QPainterPath m_helipadIconPath;
|
||||
QPainterPath m_helipadIconPath, m_helipadBoundsPath;
|
||||
FGPositionedRef m_selection;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue