diff options
author | Andrea Weikert <elubie@gmx.net> | 2011-01-17 22:39:25 +0300 |
---|---|---|
committer | Andrea Weikert <elubie@gmx.net> | 2011-01-17 22:39:25 +0300 |
commit | 0b1e5170526a802ba68773e6807480d8fa1650ce (patch) | |
tree | 1a7842c556891a5c762946526026299a6f1e2bec /intern/ghost | |
parent | d591ab53550d73e05e1a49eecdded014c53cf0cb (diff) |
fix compile on MinGW, missing define in the mingw headers.
Diffstat (limited to 'intern/ghost')
-rw-r--r-- | intern/ghost/intern/GHOST_SystemPathsWin32.cpp | 28 |
1 files changed, 25 insertions, 3 deletions
diff --git a/intern/ghost/intern/GHOST_SystemPathsWin32.cpp b/intern/ghost/intern/GHOST_SystemPathsWin32.cpp index 9f4ff98c799..a965906ebce 100644 --- a/intern/ghost/intern/GHOST_SystemPathsWin32.cpp +++ b/intern/ghost/intern/GHOST_SystemPathsWin32.cpp @@ -35,6 +35,29 @@ #include <windows.h> #include <shlobj.h> +#if defined(__MINGW32__) || defined(__CYGWIN__) + +#if !defined(SHARD_PIDL) +#define SHARD_PIDL 0x00000001L +#endif + +#if !defined(SHARD_PATHA) +#define SHARD_PATHA 0x00000002L +#endif + +#if !defined(SHARD_PATHA) +#define SHARD_PATHW 0x00000003L +#endif + +#if !defined(SHARD_PATH) +#ifdef UNICODE +#define SHARD_PATH SHARD_PATHW +#else +#define SHARD_PATH SHARD_PATHA +#endif +#endif + +#endif GHOST_SystemPathsWin32::GHOST_SystemPathsWin32() { @@ -82,7 +105,6 @@ const GHOST_TUns8* GHOST_SystemPathsWin32::getBinaryDir() const void GHOST_SystemPathsWin32::addToSystemRecentFiles(const char* filename) const { - /* SHARD_PATHA is for ansi strings, use SHARD_PATHW for wide */ - SHAddToRecentDocs(SHARD_PATHA,filename); - + /* SHARD_PATH resolves to SHARD_PATHA for non-UNICODE build */ + SHAddToRecentDocs(SHARD_PATH,filename); } |