X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/76626af21b305a78a55dc715b4641c6552392257..6b037754f53cc35e177bf6787bace26c7cecc6e1:/src/common/object.cpp diff --git a/src/common/object.cpp b/src/common/object.cpp index 52d95152bb..15e3f0fec0 100644 --- a/src/common/object.cpp +++ b/src/common/object.cpp @@ -22,7 +22,7 @@ #ifndef WX_PRECOMP #include "wx/hash.h" -#ifdef USE_SERIAL +#ifdef wxUSE_SERIAL #include "wx/objstrm.h" #include "wx/serbase.h" #endif @@ -31,13 +31,20 @@ #include #include -#if (WXDEBUG && USE_MEMORY_TRACING) || USE_DEBUG_CONTEXT +#if (defined(__WXDEBUG__) && wxUSE_MEMORY_TRACING) || wxUSE_DEBUG_CONTEXT #include "wx/memory.h" #endif -#if WXDEBUG || USE_DEBUG_CONTEXT +#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT // for wxObject::Dump - #include +#if wxUSE_IOSTREAMH +# include +#else +# include +# ifdef _MSC_VER + using namespace std; +# endif +#endif #endif #if !USE_SHARED_LIBRARY @@ -53,7 +60,7 @@ wxHashTable* wxClassInfo::sm_classTable = (wxHashTable*) NULL; wxObject::wxObject(void) { m_refData = (wxObjectRefData *) NULL; -#ifdef USE_SERIAL +#ifdef wxUSE_SERIAL m_serialObj = (wxObject_Serialize *)NULL; #endif } @@ -61,7 +68,7 @@ wxObject::wxObject(void) wxObject::~wxObject(void) { UnRef(); -#ifdef USE_SERIAL +#ifdef wxUSE_SERIAL if (m_serialObj) delete m_serialObj; #endif @@ -83,7 +90,7 @@ bool wxObject::IsKindOf(wxClassInfo *info) const return FALSE; } -#if WXDEBUG || USE_DEBUG_CONTEXT +#if defined(__WXDEBUG__) || wxUSE_DEBUG_CONTEXT void wxObject::Dump(ostream& str) { if (GetClassInfo() && GetClassInfo()->GetClassName()) @@ -93,7 +100,7 @@ void wxObject::Dump(ostream& str) } #endif -#if WXDEBUG && USE_MEMORY_TRACING +#if defined(__WXDEBUG__) && wxUSE_MEMORY_TRACING #ifdef new #undef new @@ -111,7 +118,7 @@ void wxObject::operator delete (void * buf) // VC++ 6.0 #if _MSC_VER >= 1200 -void operator delete(void* pData, char* /* fileName */, int /* lineNum */) +void wxObject::operator delete(void* pData, char* /* fileName */, int /* lineNum */) { ::operator delete(pData); } @@ -258,7 +265,7 @@ wxObject *wxCreateDynamicObject(const char *name) return (wxObject*) NULL; } -#ifdef USE_SERIAL +#ifdef wxUSE_SERIAL #include "wx/serbase.h" #include "wx/dynlib.h"