Added some ifdefs around the vc9 fixes so that mse still compiles with msvc7 and wxWidget 2.6

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@1568 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2010-12-30 16:50:20 +00:00
parent 70471251e4
commit 809d9b747a
6 changed files with 30 additions and 7 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ DECLARE_TYPEOF_COLLECTION(ScriptParseError);
// ----------------------------------------------------------------------------- : Debug utilities
#if defined(_MSC_VER) && defined(_DEBUG)
#if defined(_MSC_VER) && defined(_DEBUG) && defined(_CRT_WIDE)
void msvc_assert(const wchar_t* msg, const wchar_t* expr, const wchar_t* file, unsigned line) {
if (IsDebuggerPresent()) {
wchar_t buffer[1024];
+12 -1
View File
@@ -18,6 +18,7 @@
# pragma warning (disable: 4100) // unreferenced formal parameter
# pragma warning (disable: 4355) // 'this' : used in base member initializer list
# pragma warning (disable: 4800) // 'int' : forcing value to bool 'true' or 'false' (performance warning)
# pragma warning (disable: 4675) // resolved overload was found by argument-dependent lookup (occurs in some boost header)
#endif
// ----------------------------------------------------------------------------- : Includes
@@ -64,6 +65,16 @@ typedef wxOutputStream OutputStream;
// wx >= 2.9 requires the use of HandleWindowEvent on windows, instead of ProcessEvent
#define HandleWindowEvent ProcessEvent
#endif
#if wxVERSION_NUMBER < 2700
// is it worth it to still support wx2.6?
#define wxFD_SAVE wxSAVE
#define wxFD_OPEN wxOPEN
#define wxFD_OVERWRITE_PROMPT wxOVERWRITE_PROMPT
#define SetDeviceClippingRegion SetClippingRegion
typedef wxEvent wxMouseCaptureLostEvent;
#define EVT_MOUSE_CAPTURE_LOST(handler) // ignore
#define wxEVT_MOUSE_CAPTURE_LOST 12345678 // not an actual event type
#endif
// ----------------------------------------------------------------------------- : Other aliasses
@@ -101,7 +112,7 @@ class FileName : public wxString {
#define for if(false);else for
#endif
#ifdef _DEBUG
#if defined(_DEBUG) && defined(_CRT_WIDE)
// Use OutputDebugString/DebugBreak for assertions if in debug mode
void msvc_assert(const wchar_t*, const wchar_t*, const wchar_t*, unsigned);
#undef assert