X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/6ba549f2a5674c41abbd140197c81d08f4df21d7..792064e93f052115705de2f17c9ac0fe5de4bdb3:/contrib/src/xml/xh_stbmp.cpp diff --git a/contrib/src/xml/xh_stbmp.cpp b/contrib/src/xml/xh_stbmp.cpp index 903b84b92d..8ec8d5553c 100644 --- a/contrib/src/xml/xh_stbmp.cpp +++ b/contrib/src/xml/xh_stbmp.cpp @@ -21,8 +21,6 @@ #include "wx/xml/xh_stbmp.h" #include "wx/statbmp.h" -#include "wx/image.h" -#include "wx/bitmap.h" wxStaticBitmapXmlHandler::wxStaticBitmapXmlHandler() : wxXmlResourceHandler() @@ -31,14 +29,9 @@ wxStaticBitmapXmlHandler::wxStaticBitmapXmlHandler() wxObject *wxStaticBitmapXmlHandler::DoCreateResource() { - wxImage img(GetParamValue(_T("bitmap"))); - wxSize sz = GetSize(); - - if (!(sz == wxDefaultSize)) img.Rescale(sz.x, sz.y); - wxStaticBitmap *bmp = new wxStaticBitmap(m_ParentAsWindow, GetID(), - img.ConvertToBitmap(), + GetBitmap(_T("bitmap"), GetSize()), GetPosition(), GetSize(), GetStyle(), GetName()