X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f910f4d5cb822dddfda3d5be2f749d36ece5911f..42fb9cdf6f1778ce06d5545fc37c85a966521f6c:/interface/wx/object.h diff --git a/interface/wx/object.h b/interface/wx/object.h index c33355f97f..6f2dde528a 100644 --- a/interface/wx/object.h +++ b/interface/wx/object.h @@ -125,7 +125,7 @@ protected: It's declared @c protected so that wxObjectRefData instances will never be destroyed directly but only as result of a DecRef() call. */ - ~wxObjectRefData(); + virtual ~wxObjectRefData(); public: /** @@ -200,32 +200,13 @@ public: Performs dereferencing, for those objects that use reference counting. */ - ~wxObject(); - - /** - A virtual function that may be redefined by derived classes to allow dumping of - memory states. - - This function is only defined in debug build and exists only if @c __WXDEBUG__ - is defined. - - @param stream - Stream on which to output dump information. - - @remarks Currently wxWidgets does not define Dump() for derived classes, - but programmers may wish to use it for their own applications. - Be sure to call the Dump member of the class's base class to allow all - information to be dumped. - The implementation of this function in wxObject just writes - the class name of the object. - */ - void Dump(ostream& stream); + virtual ~wxObject(); /** This virtual function is redefined for every class that requires run-time type information, when using the ::DECLARE_CLASS macro (or similar). */ - wxClassInfo* GetClassInfo(); + virtual wxClassInfo* GetClassInfo() const; /** Returns the wxObject::m_refData pointer, i.e. the data referenced by this object. @@ -251,7 +232,7 @@ public: @return @true if the class represented by info is the same class as this one or is derived from it. */ - bool IsKindOf(wxClassInfo* info); + bool IsKindOf(const wxClassInfo* info) const; /** Returns @true if this object has the same data pointer as @a obj. @@ -263,7 +244,7 @@ public: @see @ref overview_refcount */ - bool IsSameAs(const wxObject& obj); + bool IsSameAs(const wxObject& obj) const; /** Makes this object refer to the data in @a clone. @@ -373,34 +354,28 @@ public: /** Finds the wxClassInfo object for a class with the given @a name. */ - static wxClassInfo* FindClass(wxChar* name); + static wxClassInfo* FindClass(const wxString& className); /** Returns the name of the first base class (@NULL if none). */ - wxChar* GetBaseClassName1() const; + const wxChar* GetBaseClassName1() const; /** Returns the name of the second base class (@NULL if none). */ - wxChar* GetBaseClassName2() const; + const wxChar* GetBaseClassName2() const; /** Returns the string form of the class name. */ - wxChar* GetClassName() const; + const wxChar* GetClassName() const; /** Returns the size of the class. */ int GetSize() const; - /** - Initializes pointers in the wxClassInfo objects for fast execution of IsKindOf(). - Called in base wxWidgets library initialization. - */ - static void InitializeClasses(); - /** Returns @true if this class info can create objects of the associated class. */ @@ -409,7 +384,7 @@ public: /** Returns @true if this class is a kind of (inherits from) the given class. */ - bool IsKindOf(wxClassInfo* info); + bool IsKindOf(const wxClassInfo* info) const; }; @@ -572,7 +547,7 @@ public: // Global functions/macros // ============================================================================ -/** @ingroup group_funcmacro_rtti */ +/** @addtogroup group_funcmacro_rtti */ //@{ /** @@ -828,7 +803,7 @@ wxObject *wxCreateDynamicObject(const wxString& className); //@} -/** @ingroup group_funcmacro_debug */ +/** @addtogroup group_funcmacro_debug */ //@{ /**