X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/56d2f75071fc2a29ec10abe97c5a908bb35f30f4..8173fefe0a9d61cfe5244a301044aa2269bc1c31:/contrib/src/xml/xh_chckb.cpp?ds=sidebyside diff --git a/contrib/src/xml/xh_chckb.cpp b/contrib/src/xml/xh_chckb.cpp index d2d3c15f1a..c675c6663e 100644 --- a/contrib/src/xml/xh_chckb.cpp +++ b/contrib/src/xml/xh_chckb.cpp @@ -27,20 +27,21 @@ wxCheckBoxXmlHandler::wxCheckBoxXmlHandler() : wxXmlResourceHandler() { + AddWindowStyles(); } wxObject *wxCheckBoxXmlHandler::DoCreateResource() { - wxCheckBox *control = new wxCheckBox(m_ParentAsWindow, + wxCheckBox *control = new wxCheckBox(m_parentAsWindow, GetID(), - GetText(_T("label")), + GetText(wxT("label")), GetPosition(), GetSize(), GetStyle(), wxDefaultValidator, GetName() ); - control->SetValue( GetBool( _T("checked"))); + control->SetValue( GetBool( wxT("checked"))); SetupWindow(control); return control; @@ -50,7 +51,7 @@ wxObject *wxCheckBoxXmlHandler::DoCreateResource() bool wxCheckBoxXmlHandler::CanHandle(wxXmlNode *node) { - return node->GetName() == _T("checkbox"); + return IsOfClass(node, wxT("wxCheckBox")); } #endif