X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0a53b9b8fe6fc88f243f777db03bafa3a9651701..0164f8ebfd7bbf1b0a96cb67641cd607c022ae9f:/src/common/rendcmn.cpp?ds=sidebyside diff --git a/src/common/rendcmn.cpp b/src/common/rendcmn.cpp index 2cedd7f4de..572600a9bd 100644 --- a/src/common/rendcmn.cpp +++ b/src/common/rendcmn.cpp @@ -42,8 +42,8 @@ // wxRendererPtr: auto pointer holding the global renderer // ---------------------------------------------------------------------------- -wxDECLARE_SCOPED_PTR(wxRendererNative, wxRendererPtrBase); -wxDEFINE_SCOPED_PTR(wxRendererNative, wxRendererPtrBase); +wxDECLARE_SCOPED_PTR(wxRendererNative, wxRendererPtrBase) +wxDEFINE_SCOPED_PTR(wxRendererNative, wxRendererPtrBase) class wxRendererPtr : public wxRendererPtrBase { @@ -63,12 +63,7 @@ public: } // return the global and unique wxRendererPtr - static wxRendererPtr& Get() - { - static wxRendererPtr s_renderer; - - return s_renderer; - } + static wxRendererPtr& Get(); private: wxRendererPtr() : wxRendererPtrBase(NULL) { m_initialized = false; } @@ -91,6 +86,14 @@ private: DECLARE_NO_COPY_CLASS(wxRendererPtr) }; +// return the global and unique wxRendererPtr +/*static*/ wxRendererPtr& wxRendererPtr::Get() +{ + static wxRendererPtr s_renderer; + + return s_renderer; +} + #if wxUSE_DYNLIB_CLASS // ----------------------------------------------------------------------------