X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/068becf5625117fda98c6a6f94433c5b5147e367..56c6aab7e6fe6dccd753fd94d07a44ded2ba70d1:/include/wx/geometry.h diff --git a/include/wx/geometry.h b/include/wx/geometry.h index 2aa92a80f9..10c60516d3 100644 --- a/include/wx/geometry.h +++ b/include/wx/geometry.h @@ -379,6 +379,11 @@ inline void wxPoint2DDouble::SetVectorLength( wxDouble length ) m_y = (m_y * length / before) ; } +inline void wxPoint2DDouble::Normalize() +{ + SetVectorLength( 1 ); +} + inline wxDouble wxPoint2DDouble::GetDistance( const wxPoint2DDouble &pt ) const { return sqrt( GetDistanceSquare( pt ) );