X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/5ccb95f690bd7265b1b86718149a79bb97dcf4d8..b0fc907f70d0059216c8f447d6bb9f51a5de1571:/include/wx/geometry.h diff --git a/include/wx/geometry.h b/include/wx/geometry.h index 4c1e5ad871..237f84dca5 100644 --- a/include/wx/geometry.h +++ b/include/wx/geometry.h @@ -20,16 +20,8 @@ #include "wx/gdicmn.h" #include "wx/math.h" -#if defined(__WXMSW__) && !defined(__WXWINCE__) - #define wxMulDivInt32( a , b , c ) ::MulDiv( a , b , c ) -#elif defined( __WXMAC__ ) - #define wxMulDivInt32( a , b , c ) ( (wxInt32) ( ( (wxInt64)(a) * (wxInt64)(b) ) / (wxInt64)(c) ) ) -#else - #define wxMulDivInt32( a , b , c ) ((wxInt32)((a)*(((wxDouble)b)/((wxDouble)c)))) -#endif - -class WXDLLIMPEXP_BASE wxDataInputStream; -class WXDLLIMPEXP_BASE wxDataOutputStream; +class WXDLLIMPEXP_FWD_BASE wxDataInputStream; +class WXDLLIMPEXP_FWD_BASE wxDataOutputStream; // clipping from Cohen-Sutherland @@ -387,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 ) );