Unicode fixes for Watcom (part of patch 813225)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@24009 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin 2003-09-30 12:41:46 +00:00
parent 2ef76992c8
commit 18da7cf292
3 changed files with 15 additions and 6 deletions

View File

@ -619,6 +619,10 @@ typedef int wxWindowID;
#define except(x) catch(...) #define except(x) catch(...)
#endif // Metrowerks #endif // Metrowerks
#if defined(__WATCOMC__)
typedef short mode_t;
#endif
// where should i put this? we need to make sure of this as it breaks // where should i put this? we need to make sure of this as it breaks
// the <iostream> code. // the <iostream> code.
#if !wxUSE_IOSTREAMH && defined(__WXDEBUG__) #if !wxUSE_IOSTREAMH && defined(__WXDEBUG__)

View File

@ -74,9 +74,10 @@ enum wxSeekMode
// Microsoft compiler loves underscores, feed them to it // Microsoft compiler loves underscores, feed them to it
#if defined( __VISUALC__ ) \ #if defined( __VISUALC__ ) \
|| ( defined(__MINGW32__) && !defined(__WINE__) && wxCHECK_W32API_VERSION( 0, 5 ) ) \ || ( defined(__MINGW32__) && !defined(__WINE__) && wxCHECK_W32API_VERSION( 0, 5 ) ) \
|| ( defined(__MWERKS__) && defined(__WXMSW__) ) || ( defined(__MWERKS__) && defined(__WXMSW__) ) \
|| ( defined(__WATCOMC__) && defined(__WXMSW__) )
// functions // functions
#ifdef __BORLANDC__ #if defined(__BORLANDC__) || defined(__WATCOMC__)
#define _tell tell #define _tell tell
#endif #endif
#define wxClose _close #define wxClose _close
@ -116,10 +117,14 @@ enum wxSeekMode
#endif #endif
// types // types
#if defined(__WATCOMC__)&& wxUSE_UNICODE
#define wxStructStat struct _wstat
#else
#define wxStructStat struct _stat #define wxStructStat struct _stat
#endif
// constants (unless already defined by the user code) // constants (unless already defined by the user code)
#if !defined(O_RDONLY) && !defined(__BORLANDC__) #if !defined(O_RDONLY) && !defined(__BORLANDC__) && !defined(__WATCOMC__)
#define O_RDONLY _O_RDONLY #define O_RDONLY _O_RDONLY
#define O_WRONLY _O_WRONLY #define O_WRONLY _O_WRONLY
#define O_RDWR _O_RDWR #define O_RDWR _O_RDWR
@ -128,7 +133,7 @@ enum wxSeekMode
#define O_BINARY _O_BINARY #define O_BINARY _O_BINARY
#endif #endif
#ifndef __BORLANDC__ #if !defined(__BORLANDC__) && !defined(__WATCOMC__)
#define S_IFMT _S_IFMT #define S_IFMT _S_IFMT
#define S_IFDIR _S_IFDIR #define S_IFDIR _S_IFDIR
#define S_IFREG _S_IFREG #define S_IFREG _S_IFREG

View File

@ -530,8 +530,8 @@ wxSafeShowMessage(const wxString& title, const wxString& text);
(long)rc, wxSysErrorMsg(rc)) (long)rc, wxSysErrorMsg(rc))
#else // !VC++ #else // !VC++
#define wxLogApiError(api, rc) \ #define wxLogApiError(api, rc) \
wxLogDebug(wxT("In file %s at line %d: '%s' failed with " \ wxLogDebug(wxT("In file %s at line %d: '%s' failed with ") \
"error 0x%08lx (%s)."), \ wxT("error 0x%08lx (%s)."), \
__TFILE__, __LINE__, api, \ __TFILE__, __LINE__, api, \
(long)rc, wxSysErrorMsg(rc)) (long)rc, wxSysErrorMsg(rc))
#endif // VC++/!VC++ #endif // VC++/!VC++