X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/af8fc1161cc10818b95bea8f08c2bd0995a1964d..0bbe61b8c18a1795189f0cf73cc61c14a0fb846d:/src/msw/checklst.cpp diff --git a/src/msw/checklst.cpp b/src/msw/checklst.cpp index 98a4e6763b..fd480f4f70 100644 --- a/src/msw/checklst.cpp +++ b/src/msw/checklst.cpp @@ -47,6 +47,7 @@ #include "wx/renderer.h" #include "wx/msw/private.h" +#include "wx/msw/dc.h" // ---------------------------------------------------------------------------- // private functions @@ -174,8 +175,9 @@ bool wxCheckListBoxItem::OnDrawItem(wxDC& dc, const wxRect& rc, if ( !wxOwnerDrawn::OnDrawItem(dc, rc, act, stat) ) return false; + wxMSWDCImpl *impl = (wxMSWDCImpl*) dc.GetImpl(); // now draw the check mark part - HDC hdc = GetHdcOf(dc); + HDC hdc = GetHdcOf(*impl); int nBmpWidth = ::GetSystemMetrics(SM_CXMENUCHECK), nBmpHeight = ::GetSystemMetrics(SM_CYMENUCHECK);