From: Ryan Norton Date: Thu, 7 Oct 2004 23:32:04 +0000 (+0000) Subject: fix darwin defines X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/8a9c20b016d88b85db8a1f564a2249057db0ca77 fix darwin defines git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@29721 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/wxchar.h b/include/wx/wxchar.h index e6f54b771e..0b3a697e50 100644 --- a/include/wx/wxchar.h +++ b/include/wx/wxchar.h @@ -362,7 +362,7 @@ #define wxCtime _tctime #else /* !TCHAR-aware compilers */ - #if __DARWIN__ && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) && !defined(__MWERKS__) + #if !defined(__MWERKS__) && defined(__DARWIN__) && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) /* even though they are defined and "implemented", they are bad and just stubs so we need our own - we need these even in ANSI builds!! */ #define mbstowcs wxInternalMbstowcs @@ -373,7 +373,7 @@ #endif /* No UNICODE in the c library except wchar_t typedef on mac OSX 10.2 and less - roll our own */ - #if wxUSE_UNICODE && __DARWIN__ && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) && !defined(__MWERKS__) + #if !defined(__MWERKS__) && wxUSE_UNICODE && defined(__DARWIN__) && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) /* we need everything! */ #define wxNEED_WX_STRING_H diff --git a/src/common/wxchar.cpp b/src/common/wxchar.cpp index 1aa8374a8c..e955415642 100644 --- a/src/common/wxchar.cpp +++ b/src/common/wxchar.cpp @@ -1043,7 +1043,7 @@ WXDLLEXPORT int wxTolower(wxChar ch) { return (wxChar)CharLower((LPTSTR)(ch)); } WXDLLEXPORT int wxToupper(wxChar ch) { return (wxChar)CharUpper((LPTSTR)(ch)); } #endif -#if __DARWIN__ && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) +#if defined(__DARWIN__) && ( MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_2 ) WXDLLEXPORT size_t wxInternalMbstowcs (wchar_t * out, const char * in, size_t outlen) { @@ -1117,9 +1117,10 @@ WXDLLEXPORT int wxIsupper(wxChar ch) { return CFCharacterSetIsCharacterMember(cf WXDLLEXPORT int wxIsxdigit(wxChar ch) { return wxIsdigit(ch) || (ch>='a' && ch<='f') || (ch>='A' && ch<='F'); } WXDLLEXPORT int wxTolower(wxChar ch) { return (wxChar)tolower((char)(ch)); } WXDLLEXPORT int wxToupper(wxChar ch) { return (wxChar)toupper((char)(ch)); } -#endif -#endif +#endif // wxNEED_WX_CTYPE_H + +#endif // defined(__DARWIN__) and OSX <= 10.2 #ifndef wxStrdupA