diff options
-rw-r--r-- | backends/audiocd/win32/win32-audiocd.cpp | 1 | ||||
-rw-r--r-- | backends/dialogs/win32/win32-dialogs.cpp | 3 | ||||
-rw-r--r-- | backends/fs/windows/windows-fs.h | 5 | ||||
-rw-r--r-- | backends/midi/windows.cpp | 2 | ||||
-rw-r--r-- | backends/platform/sdl/win32/win32-main.cpp | 1 | ||||
-rw-r--r-- | backends/platform/sdl/win32/win32-window.cpp | 1 | ||||
-rw-r--r-- | backends/platform/sdl/win32/win32.cpp | 1 | ||||
-rw-r--r-- | backends/saves/windows/windows-saves.cpp | 4 | ||||
-rw-r--r-- | backends/taskbar/win32/win32-taskbar.cpp | 3 | ||||
-rw-r--r-- | common/scummsys.h | 5 | ||||
-rw-r--r-- | common/translation.cpp | 2 | ||||
-rw-r--r-- | common/util.h | 4 | ||||
-rw-r--r-- | engines/engine.cpp | 2 |
13 files changed, 4 insertions, 30 deletions
diff --git a/backends/audiocd/win32/win32-audiocd.cpp b/backends/audiocd/win32/win32-audiocd.cpp index 7269910506..9ffcc00ec3 100644 --- a/backends/audiocd/win32/win32-audiocd.cpp +++ b/backends/audiocd/win32/win32-audiocd.cpp @@ -46,7 +46,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> -#undef ARRAYSIZE // winnt.h defines ARRAYSIZE, but we want our own one... #include "backends/audiocd/win32/win32-audiocd.h" diff --git a/backends/dialogs/win32/win32-dialogs.cpp b/backends/dialogs/win32/win32-dialogs.cpp index e34a08c07b..fca0601a71 100644 --- a/backends/dialogs/win32/win32-dialogs.cpp +++ b/backends/dialogs/win32/win32-dialogs.cpp @@ -56,9 +56,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> -#if defined(ARRAYSIZE) -#undef ARRAYSIZE -#endif #endif #include <shlobj.h> diff --git a/backends/fs/windows/windows-fs.h b/backends/fs/windows/windows-fs.h index 3758877f05..4be4cbf57e 100644 --- a/backends/fs/windows/windows-fs.h +++ b/backends/fs/windows/windows-fs.h @@ -25,12 +25,7 @@ #include "backends/fs/abstract-fs.h" -#if defined(ARRAYSIZE) -#undef ARRAYSIZE -#endif #include <windows.h> -// winnt.h defines ARRAYSIZE, but we want our own one... -#undef ARRAYSIZE #ifdef _WIN32_WCE #undef GetCurrentDirectory #endif diff --git a/backends/midi/windows.cpp b/backends/midi/windows.cpp index 52a46200cb..35608fd228 100644 --- a/backends/midi/windows.cpp +++ b/backends/midi/windows.cpp @@ -29,8 +29,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> -// winnt.h defines ARRAYSIZE, but we want our own one... -#undef ARRAYSIZE #include "audio/musicplugin.h" #include "audio/mpu401.h" diff --git a/backends/platform/sdl/win32/win32-main.cpp b/backends/platform/sdl/win32/win32-main.cpp index 4e9f6a49da..0a7c1dd8e2 100644 --- a/backends/platform/sdl/win32/win32-main.cpp +++ b/backends/platform/sdl/win32/win32-main.cpp @@ -33,7 +33,6 @@ // "ARRAYSIZE" for example. #define WIN32_LEAN_AND_MEAN #include <windows.h> -#undef ARRAYSIZE // winnt.h defines ARRAYSIZE, but we want our own one... #include "backends/platform/sdl/win32/win32.h" #include "backends/plugins/sdl/sdl-provider.h" diff --git a/backends/platform/sdl/win32/win32-window.cpp b/backends/platform/sdl/win32/win32-window.cpp index 8c01da0e36..47d77a8ad1 100644 --- a/backends/platform/sdl/win32/win32-window.cpp +++ b/backends/platform/sdl/win32/win32-window.cpp @@ -29,7 +29,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> -#undef ARRAYSIZE // winnt.h defines ARRAYSIZE, but we want our own one... void SdlWindow_Win32::setupIcon() { HMODULE handle = GetModuleHandle(NULL); diff --git a/backends/platform/sdl/win32/win32.cpp b/backends/platform/sdl/win32/win32.cpp index 264a0640ed..e837bbae03 100644 --- a/backends/platform/sdl/win32/win32.cpp +++ b/backends/platform/sdl/win32/win32.cpp @@ -27,7 +27,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> -#undef ARRAYSIZE // winnt.h defines ARRAYSIZE, but we want our own one... #include <shellapi.h> #if defined(__GNUC__) && defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) // required for SHGFP_TYPE_CURRENT in shlobj.h diff --git a/backends/saves/windows/windows-saves.cpp b/backends/saves/windows/windows-saves.cpp index fec4828725..50564e974d 100644 --- a/backends/saves/windows/windows-saves.cpp +++ b/backends/saves/windows/windows-saves.cpp @@ -22,12 +22,8 @@ #if defined(WIN32) && !defined(_WIN32_WCE) && !defined(DISABLE_DEFAULT_SAVEFILEMANAGER) -#if defined(ARRAYSIZE) -#undef ARRAYSIZE -#endif #define WIN32_LEAN_AND_MEAN #include <windows.h> -#undef ARRAYSIZE // winnt.h defines ARRAYSIZE, but we want our own one... #if defined(__GNUC__) && defined(__MINGW32__) && !defined(__MINGW64_VERSION_MAJOR) // required for SHGFP_TYPE_CURRENT in shlobj.h #define _WIN32_IE 0x500 diff --git a/backends/taskbar/win32/win32-taskbar.cpp b/backends/taskbar/win32/win32-taskbar.cpp index f6706de72d..1a03bbd516 100644 --- a/backends/taskbar/win32/win32-taskbar.cpp +++ b/backends/taskbar/win32/win32-taskbar.cpp @@ -55,9 +55,6 @@ #define _WIN32_WINNT _WIN32_WINNT_WIN7 #include <windows.h> - #if defined(ARRAYSIZE) - #undef ARRAYSIZE - #endif #endif #include <shlobj.h> diff --git a/common/scummsys.h b/common/scummsys.h index 3b22272b5a..b205665653 100644 --- a/common/scummsys.h +++ b/common/scummsys.h @@ -117,11 +117,6 @@ #endif - #if defined(ARRAYSIZE) - // VS2005beta2 introduces new stuff in winnt.h - #undef ARRAYSIZE - #endif - #endif #if defined(__QNXNTO__) diff --git a/common/translation.cpp b/common/translation.cpp index 35e5b6e4c3..1debabfb7d 100644 --- a/common/translation.cpp +++ b/common/translation.cpp @@ -23,8 +23,6 @@ #if defined(WIN32) #define WIN32_LEAN_AND_MEAN #include <windows.h> -// winnt.h defines ARRAYSIZE, but we want our own one... - this is needed before including util.h -#undef ARRAYSIZE #endif #define TRANSLATIONS_DAT_VER 3 diff --git a/common/util.h b/common/util.h index 2d6a36d086..77d7523034 100644 --- a/common/util.h +++ b/common/util.h @@ -56,6 +56,10 @@ template<typename T> inline T CLIP(T v, T amin, T amax) */ template<typename T> inline void SWAP(T &a, T &b) { T tmp = a; a = b; b = tmp; } +#ifdef ARRAYSIZE +#undef ARRAYSIZE +#endif + /** * Macro which determines the number of entries in a fixed size array. */ diff --git a/engines/engine.cpp b/engines/engine.cpp index cc8c0132f9..0e7f64f8a4 100644 --- a/engines/engine.cpp +++ b/engines/engine.cpp @@ -26,8 +26,6 @@ #define WIN32_LEAN_AND_MEAN #include <windows.h> #include <direct.h> -// winnt.h defines ARRAYSIZE, but we want our own one... -#undef ARRAYSIZE #endif #include "engines/engine.h" |