1 /////////////////////////////////////////////////////////////////////////////
2 // Name: src/xrc/xh_cmdlinkbn.cpp
3 // Purpose: XRC resource for command link buttons
4 // Author: Kinaou Herve
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
10 // For compilers that support precompilation, includes "wx.h".
11 #include "wx/wxprec.h"
17 #if wxUSE_XRC && wxUSE_COMMANDLINKBUTTON
19 #include "wx/xrc/xh_cmdlinkbn.h"
21 #include "wx/commandlinkbutton.h"
23 IMPLEMENT_DYNAMIC_CLASS(wxCommandLinkButtonXmlHandler
, wxXmlResourceHandler
)
25 wxCommandLinkButtonXmlHandler::wxCommandLinkButtonXmlHandler()
26 : wxXmlResourceHandler()
28 XRC_ADD_STYLE(wxBU_LEFT
);
29 XRC_ADD_STYLE(wxBU_RIGHT
);
30 XRC_ADD_STYLE(wxBU_TOP
);
31 XRC_ADD_STYLE(wxBU_BOTTOM
);
32 XRC_ADD_STYLE(wxBU_EXACTFIT
);
36 wxObject
*wxCommandLinkButtonXmlHandler::DoCreateResource()
38 XRC_MAKE_INSTANCE(button
, wxCommandLinkButton
)
40 button
->Create(m_parentAsWindow
,
42 GetText(wxS("label")),
44 GetPosition(), GetSize(),
54 bool wxCommandLinkButtonXmlHandler::CanHandle(wxXmlNode
*node
)
56 return IsOfClass(node
, wxS("wxCommandLinkButton"));
59 #endif // wxUSE_XRC && wxUSE_COMMANDLINKBUTTON