X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/371a5b4e62eb415107e045588f614fa49e866e78..15d521a109c4de5b2e18bb7b953bfedd5505a1ee:/include/wx/ptr_scpd.h diff --git a/include/wx/ptr_scpd.h b/include/wx/ptr_scpd.h index b574491359..79ed8f3f00 100644 --- a/include/wx/ptr_scpd.h +++ b/include/wx/ptr_scpd.h @@ -68,7 +68,7 @@ private: \ name & operator=(name const &); \ \ public: \ - wxEXPLICIT name(T * ptr = NULL) \ + wxEXPLICIT name(T * ptr = NULL) \ : m_ptr(ptr) { } \ \ ~name(); \ @@ -82,6 +82,13 @@ public: \ } \ } \ \ + T *release() \ + { \ + T *ptr = m_ptr; \ + m_ptr = NULL; \ + return ptr; \ + } \ + \ T & operator*() const \ { \ wxASSERT(m_ptr != NULL); \