// Licence: wxWindows license
///////////////////////////////////////////////////////////////////////////////
// Licence: wxWindows license
///////////////////////////////////////////////////////////////////////////////
// ============================================================================
// implementation of wxOwnerDrawn class
// ============================================================================
// ctor
// ----
// ============================================================================
// implementation of wxOwnerDrawn class
// ============================================================================
// ctor
// ----
-#if defined(__WXMSW__) && defined(__WIN32__)
- uint wxOwnerDrawn::ms_nDefaultMarginWidth = GetSystemMetrics(SM_CXMENUCHECK);
+#if defined(__WXMSW__) && defined(__WIN32__) && defined(SM_CXMENUCHECK)
+ size_t wxOwnerDrawn::ms_nDefaultMarginWidth = GetSystemMetrics(SM_CXMENUCHECK);
// Win32 GDI functions and not wxWindows ones. Might help to whoever decides to
// port this code to X. (VZ)
// Win32 GDI functions and not wxWindows ones. Might help to whoever decides to
// port this code to X. (VZ)
#ifdef O_DRAW_NATIVE_API
int nPrevMode = SetBkMode(hdc, TRANSPARENT);
HBRUSH hbr = CreateSolidBrush(colBack),
#ifdef O_DRAW_NATIVE_API
int nPrevMode = SetBkMode(hdc, TRANSPARENT);
HBRUSH hbr = CreateSolidBrush(colBack),
RECT rectAll = { rc.GetLeft(), rc.GetTop(), rc.GetRight(), rc.GetBottom() };
FillRect(hdc, &rectAll, hbr);
RECT rectAll = { rc.GetLeft(), rc.GetTop(), rc.GetRight(), rc.GetBottom() };
FillRect(hdc, &rectAll, hbr);
DrawState(hdc, NULL, NULL,
(LPARAM)(const char *)m_strName, m_strName.Length(),
x, rc.y, rc.GetWidth(), rc.GetHeight(),
DrawState(hdc, NULL, NULL,
(LPARAM)(const char *)m_strName, m_strName.Length(),
x, rc.y, rc.GetWidth(), rc.GetHeight(),
// then draw a check mark into it
RECT rect = { 0, 0, GetMarginWidth(), m_nHeight };
// then draw a check mark into it
RECT rect = { 0, 0, GetMarginWidth(), m_nHeight };
DrawFrameControl(hdcMem, &rect, DFC_MENU, DFCS_MENUCHECK);
DrawFrameControl(hdcMem, &rect, DFC_MENU, DFCS_MENUCHECK);
// finally copy it to screen DC and clean up
BitBlt(hdc, rc.x, rc.y, GetMarginWidth(), m_nHeight,
// finally copy it to screen DC and clean up
BitBlt(hdc, rc.x, rc.y, GetMarginWidth(), m_nHeight,