X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fef15b42f36ea19d7162f4ff2750423cc954e7e3..53faea431638ee5c0013a2c888215c751fa6437b:/src/msw/cursor.cpp diff --git a/src/msw/cursor.cpp b/src/msw/cursor.cpp index 4cea893b6b..e914dff561 100644 --- a/src/msw/cursor.cpp +++ b/src/msw/cursor.cpp @@ -49,9 +49,7 @@ // wxWin macros // ---------------------------------------------------------------------------- -#if !USE_SHARED_LIBRARIES IMPLEMENT_DYNAMIC_CLASS(wxCursor, wxCursorBase) -#endif // ---------------------------------------------------------------------------- // wxCursorRefData @@ -67,8 +65,13 @@ wxCursorRefData::wxCursorRefData() void wxCursorRefData::Free() { - if ( m_hCursor && m_destroyCursor ) - ::DestroyCursor((HCURSOR)m_hCursor); + if ( m_hCursor ) + { + if ( m_destroyCursor ) + ::DestroyCursor((HCURSOR)m_hCursor); + + m_hCursor = 0; + } } // ----------------------------------------------------------------------------