wxFont wxSystemSettings::GetSystemFont(int index)
{
HFONT hFont = (HFONT) ::GetStockObject(index);
- if ( hFont != NULL )
+ if ( hFont != (HFONT) NULL )
{
LOGFONT lf;
if ( ::GetObject(hFont, sizeof(LOGFONT), &lf) != 0 )
return ::GetSystemMetrics(SM_CXDOUBLECLK);
case wxSYS_DCLICK_Y:
return ::GetSystemMetrics(SM_CYDOUBLECLK);
-#ifdef __WIN32__
+#if defined(__WIN32__) && defined(SM_CXDRAG)
case wxSYS_DRAG_X:
return ::GetSystemMetrics(SM_CXDRAG);
case wxSYS_DRAG_Y:
return ::GetSystemMetrics(SM_CXSCREEN);
case wxSYS_SCREEN_Y:
return ::GetSystemMetrics(SM_CYSCREEN);
-#ifdef __WIN32__
+
+#if defined(__WIN32__) && defined(SM_CXSIZEFRAME)
case wxSYS_FRAMESIZE_X:
return ::GetSystemMetrics(SM_CXSIZEFRAME);
case wxSYS_FRAMESIZE_Y:
return ::GetSystemMetrics(SM_CYCAPTION);
case wxSYS_MENU_Y:
return ::GetSystemMetrics(SM_CYMENU);
-#ifdef __WIN32__
+#if defined(__WIN32__) && defined(SM_NETWORK)
case wxSYS_NETWORK_PRESENT:
return ::GetSystemMetrics(SM_NETWORK) & 0x0001;
#endif
case wxSYS_PENWINDOWS_PRESENT:
return ::GetSystemMetrics(SM_PENWINDOWS);
-#ifdef __WIN32__
+#if defined(__WIN32__) && defined(SM_SHOWSOUNDS)
case wxSYS_SHOW_SOUNDS:
return ::GetSystemMetrics(SM_SHOWSOUNDS);
#endif