]> git.saurik.com Git - wxWidgets.git/blame - src/xrc/xh_stbmp.cpp
docopydocs is not needed for this script.
[wxWidgets.git] / src / xrc / xh_stbmp.cpp
CommitLineData
78d14f80
VS
1/////////////////////////////////////////////////////////////////////////////
2// Name: xh_stbmp.cpp
b5d6954b 3// Purpose: XRC resource for wxStaticBitmap
78d14f80
VS
4// Author: Vaclav Slavik
5// Created: 2000/04/22
6// RCS-ID: $Id$
7// Copyright: (c) 2000 Vaclav Slavik
8// Licence: wxWindows licence
9/////////////////////////////////////////////////////////////////////////////
f80ea77b 10
78d14f80
VS
11// For compilers that support precompilation, includes "wx.h".
12#include "wx/wxprec.h"
13
14#ifdef __BORLANDC__
15 #pragma hdrstop
16#endif
17
621be1ec 18#if wxUSE_XRC
a1e4ec87 19
78d14f80
VS
20#include "wx/xrc/xh_stbmp.h"
21#include "wx/statbmp.h"
22
854e189f
VS
23IMPLEMENT_DYNAMIC_CLASS(wxStaticBitmapXmlHandler, wxXmlResourceHandler)
24
f80ea77b
WS
25wxStaticBitmapXmlHandler::wxStaticBitmapXmlHandler()
26: wxXmlResourceHandler()
78d14f80
VS
27{
28 AddWindowStyles();
29}
30
31wxObject *wxStaticBitmapXmlHandler::DoCreateResource()
f80ea77b 32{
544fee32 33 XRC_MAKE_INSTANCE(bmp, wxStaticBitmap)
f2588180
VS
34
35 bmp->Create(m_parentAsWindow,
36 GetID(),
db59a97c 37 GetBitmap(wxT("bitmap"), wxART_OTHER, GetSize()),
f2588180
VS
38 GetPosition(), GetSize(),
39 GetStyle(),
40 GetName());
41
78d14f80 42 SetupWindow(bmp);
f80ea77b 43
78d14f80
VS
44 return bmp;
45}
46
78d14f80
VS
47bool wxStaticBitmapXmlHandler::CanHandle(wxXmlNode *node)
48{
49 return IsOfClass(node, wxT("wxStaticBitmap"));
50}
a1e4ec87 51
621be1ec 52#endif // wxUSE_XRC