Schematic object hit testing improvements.
This commit is contained in:
@@ -112,17 +112,16 @@ void MARKER_BASE::SetData( int aErrorCode, const wxPoint& aMarkerPos,
|
||||
}
|
||||
|
||||
|
||||
/******************************************************/
|
||||
bool MARKER_BASE::HitTestMarker( const wxPoint& refPos )
|
||||
/******************************************************/
|
||||
bool MARKER_BASE::HitTestMarker( const wxPoint& refPos ) const
|
||||
{
|
||||
wxPoint rel_pos = refPos - m_Pos;
|
||||
rel_pos.x /= m_ScalingFactor;
|
||||
rel_pos.y /= m_ScalingFactor;
|
||||
|
||||
return m_ShapeBoundingBox.Inside(rel_pos);
|
||||
return m_ShapeBoundingBox.Inside( rel_pos );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Function GetBoundingBoxMarker
|
||||
* returns the orthogonal, bounding box of this object for display purposes.
|
||||
|
||||
Reference in New Issue
Block a user