X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b5d6954b87d910969226ffade9714db7429211f3..7e4501ee3cc88ee8dd2b75e2964118e2897ec4a2:/src/xrc/xh_stbmp.cpp diff --git a/src/xrc/xh_stbmp.cpp b/src/xrc/xh_stbmp.cpp index 034fe3dd68..95edf50853 100644 --- a/src/xrc/xh_stbmp.cpp +++ b/src/xrc/xh_stbmp.cpp @@ -30,23 +30,21 @@ wxStaticBitmapXmlHandler::wxStaticBitmapXmlHandler() wxObject *wxStaticBitmapXmlHandler::DoCreateResource() { - wxStaticBitmap *bmp = new wxStaticBitmap(m_parentAsWindow, - GetID(), - GetBitmap(wxT("bitmap"), GetSize()), - GetPosition(), GetSize(), - GetStyle(), - GetName() - ); + XRC_MAKE_INSTANCE(bmp, wxStaticBitmap) + + bmp->Create(m_parentAsWindow, + GetID(), + GetBitmap(wxT("bitmap"), GetSize()), + GetPosition(), GetSize(), + GetStyle(), + GetName()); + SetupWindow(bmp); return bmp; } - - bool wxStaticBitmapXmlHandler::CanHandle(wxXmlNode *node) { return IsOfClass(node, wxT("wxStaticBitmap")); } - -