X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/07cf98cb8eb7625eeffc95e407a9fa1ad863b451..1fc8878582bcdab2a90b95fb713c4d088a0e2a57:/src/msw/ownerdrw.cpp diff --git a/src/msw/ownerdrw.cpp b/src/msw/ownerdrw.cpp index f8c26c035e..f0f1223260 100644 --- a/src/msw/ownerdrw.cpp +++ b/src/msw/ownerdrw.cpp @@ -15,6 +15,7 @@ // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" +#include "wx/msw/private.h" #ifdef __BORLANDC__ #pragma hdrstop @@ -22,7 +23,7 @@ #ifndef WX_PRECOMP #include "wx/window.h" - #include "wx/msw/private.h" +// #include "wx/msw/private.h" #include "wx/font.h" #include "wx/bitmap.h" #include "wx/dcmemory.h" @@ -30,9 +31,12 @@ #include "wx/utils.h" #endif +#include "wx/settings.h" #include "wx/ownerdrw.h" #include "wx/menuitem.h" +#if wxUSE_OWNER_DRAWN + // ============================================================================ // implementation of wxOwnerDrawn class @@ -48,6 +52,8 @@ wxOwnerDrawn::wxOwnerDrawn(const wxString& str, m_bOwnerDrawn = FALSE; m_nHeight = 0; m_nMarginWidth = ms_nLastMarginWidth; + if (wxNORMAL_FONT) + m_font = * wxNORMAL_FONT; } #if defined(__WXMSW__) && defined(__WIN32__) && defined(SM_CXMENUCHECK) @@ -251,3 +257,6 @@ bool wxOwnerDrawn::OnDrawItem(wxDC& dc, const wxRect& rc, wxODAction act, wxODSt return TRUE; } + +#endif // wxUSE_OWNER_DRAWN +