X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/df5168c427b51f1ab2b3200a5c8f7626b3d24aae..d5d29b8a2250ee3097f31dfb8593374b89128ce2:/include/wx/filefn.h diff --git a/include/wx/filefn.h b/include/wx/filefn.h index 3f00a7404f..b0daaceef5 100644 --- a/include/wx/filefn.h +++ b/include/wx/filefn.h @@ -12,7 +12,7 @@ #ifndef _FILEFN_H_ #define _FILEFN_H_ -#if defined(__GNUG__) && !defined(__APPLE__) +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma interface "filefn.h" #endif @@ -74,9 +74,10 @@ enum wxSeekMode // Microsoft compiler loves underscores, feed them to it #if defined( __VISUALC__ ) \ || ( defined(__MINGW32__) && !defined(__WINE__) && wxCHECK_W32API_VERSION( 0, 5 ) ) \ - || ( defined(__MWERKS__) && defined(__WXMSW__) ) + || ( defined(__MWERKS__) && defined(__WXMSW__) ) \ + || ( defined(__WATCOMC__) && defined(__WXMSW__) ) // functions -#ifdef __BORLANDC__ +#if defined(__BORLANDC__) || defined(__WATCOMC__) #define _tell tell #endif #define wxClose _close @@ -116,10 +117,14 @@ enum wxSeekMode #endif // types +#if defined(__WATCOMC__)&& wxUSE_UNICODE + #define wxStructStat struct _wstat +#else #define wxStructStat struct _stat +#endif // 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_WRONLY _O_WRONLY #define O_RDWR _O_RDWR @@ -128,7 +133,7 @@ enum wxSeekMode #define O_BINARY _O_BINARY #endif - #ifndef __BORLANDC__ + #if !defined(__BORLANDC__) && !defined(__WATCOMC__) #define S_IFMT _S_IFMT #define S_IFDIR _S_IFDIR #define S_IFREG _S_IFREG @@ -157,18 +162,11 @@ enum wxSeekMode WXDLLIMPEXP_BASE int wxStat( const wxChar *file_name, wxStructStat *buf ); WXDLLIMPEXP_BASE int wxAccess( const wxChar *pathname, int mode ); WXDLLIMPEXP_BASE int wxOpen( const wxChar *pathname, int flags, mode_t mode ); -#else -#if defined(__WXMAC__) && !defined(__DARWIN__) -#include -WXDLLIMPEXP_BASE int wxStat( const wxChar *file_name, wxStructStat *buf ); -WXDLLIMPEXP_BASE int wxAccess( const wxChar *pathname, int mode ); -WXDLLIMPEXP_BASE int wxOpen( const wxChar *pathname, int flags, mode_t mode ); #else #define wxOpen open #define wxStat stat #define wxAccess access #endif -#endif #endif // VC++ @@ -271,16 +269,6 @@ WXDLLIMPEXP_BASE bool wxRmdir(const wxString& dir, int flags = 0); // compatibility defines, don't use in new code #define wxDirExists wxPathExists -#if WXWIN_COMPATIBILITY_2 - #define FileExists wxFileExists - #define DirExists wxDirExists - #define IsAbsolutePath wxIsAbsolutePath - #define FileNameFromPath wxFileNameFromPath - #define PathOnly wxPathOnly - #define Dos2UnixFilename wxDos2UnixFilename - #define Unix2DosFilename wxUnix2DosFilename -#endif - // ---------------------------------------------------------------------------- // separators in file names // ----------------------------------------------------------------------------