Compilation fix after ownerdraw-refactor branch merge.

Don't use HDC in public headers, it may not be declared there. Use WXHDC
instead even if this means having ugly casts.

This fixed mingw32 compilation (see #11595).

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63252 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2010-01-24 14:15:12 +00:00
parent 5c3c137277
commit b8190883d0
2 changed files with 5 additions and 3 deletions

View File

@@ -120,7 +120,7 @@ protected:
private:
// helper function for draw std menu check mark
void DrawStdCheckMark(HDC hdc, const RECT* rc, wxODStatus stat);
void DrawStdCheckMark(WXHDC hdc, const RECT* rc, wxODStatus stat);
#endif // wxUSE_OWNER_DRAWN

View File

@@ -1035,7 +1035,7 @@ bool wxMenuItem::OnDrawItem(wxDC& dc, const wxRect& rc,
{
if ( stat & wxODChecked )
{
DrawStdCheckMark(hdc, &rcImg, stat);
DrawStdCheckMark((WXHDC)hdc, &rcImg, stat);
}
}
else
@@ -1133,8 +1133,10 @@ void DrawColorCheckMark(HDC hdc, int x, int y, int cx, int cy, HDC hdcCheckMask,
} // anonymous namespace
void wxMenuItem::DrawStdCheckMark(HDC hdc, const RECT* rc, wxODStatus stat)
void wxMenuItem::DrawStdCheckMark(WXHDC hdc_, const RECT* rc, wxODStatus stat)
{
HDC hdc = (HDC)hdc_;
#if wxUSE_UXTHEME
wxUxThemeEngine* theme = MenuDrawData::GetUxThemeEngine();
if ( theme )