X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/71908213057690d5452f72b2b9c8e62b53357170..64ea838d8f4d1853b7d850db93ee565e901d099a:/src/univ/statbmp.cpp diff --git a/src/univ/statbmp.cpp b/src/univ/statbmp.cpp index e063d46d94..5ff0f72ab6 100644 --- a/src/univ/statbmp.cpp +++ b/src/univ/statbmp.cpp @@ -1,12 +1,12 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: univ/statbmp.cpp +// Name: src/univ/statbmp.cpp // Purpose: wxStaticBitmap implementation // Author: Vadim Zeitlin // Modified by: // Created: 25.08.00 // RCS-ID: $Id$ // Copyright: (c) 2000 SciTech Software, Inc. (www.scitechsoft.com) -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // ============================================================================ @@ -17,10 +17,6 @@ // headers // ---------------------------------------------------------------------------- -#ifdef __GNUG__ - #pragma implementation "statbmp.h" -#endif - #include "wx/wxprec.h" #ifdef __BORLANDC__ @@ -29,10 +25,11 @@ #if wxUSE_STATBMP +#include "wx/statbmp.h" + #ifndef WX_PRECOMP #include "wx/dc.h" #include "wx/icon.h" - #include "wx/statbmp.h" #include "wx/validate.h" #endif @@ -43,8 +40,6 @@ // implementation // ============================================================================ -IMPLEMENT_DYNAMIC_CLASS(wxStaticBitmap, wxControl) - // ---------------------------------------------------------------------------- // wxStaticBitmap // ---------------------------------------------------------------------------- @@ -58,15 +53,15 @@ bool wxStaticBitmap::Create(wxWindow *parent, const wxString &name) { if ( !wxControl::Create(parent, id, pos, size, style, wxDefaultValidator, name) ) - return FALSE; + return false; // set bitmap first SetBitmap(label); // and adjust our size to fit it after this - SetBestSize(size); + SetInitialSize(size); - return TRUE; + return true; } // ---------------------------------------------------------------------------- @@ -109,4 +104,3 @@ void wxStaticBitmap::DoDraw(wxControlRenderer *renderer) } #endif // wxUSE_STATBMP -