X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/04857cb707be4de8083e599fc2e1967c77eb7f5e..850df2d78866c3edcf848103b5dbc7e7fa1ee5fa:/src/common/rendcmn.cpp?ds=inline diff --git a/src/common/rendcmn.cpp b/src/common/rendcmn.cpp index b97c769e7f..86e02ce8b9 100644 --- a/src/common/rendcmn.cpp +++ b/src/common/rendcmn.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////////// -// Name: common/rendcmn.cpp +// Name: src/common/rendcmn.cpp // Purpose: wxRendererNative common functions // Author: Vadim Zeitlin // Modified by: @@ -25,6 +25,8 @@ #ifndef WX_PRECOMP #include "wx/app.h" + #include "wx/log.h" + #include "wx/intl.h" #endif //WX_PRECOMP #include "wx/apptrait.h" @@ -40,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 { @@ -61,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; } @@ -89,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 // ---------------------------------------------------------------------------- @@ -201,4 +206,3 @@ wxRendererNative *wxRendererNative::Load(const wxString& name) } #endif // wxUSE_DYNLIB_CLASS -