change in XRC format

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@8491 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2000-10-07 21:56:37 +00:00
parent 3efb0e4bbd
commit e066e2566a
79 changed files with 730 additions and 606 deletions

View File

@@ -31,12 +31,11 @@ wxCheckListXmlHandler::wxCheckListXmlHandler()
wxObject *wxCheckListXmlHandler::DoCreateResource()
{
if( m_Node->GetName() == _T("checklist"))
if (m_Class == _T("wxCheckList"))
{
// need to build the list of strings from children
m_InsideBox = TRUE;
CreateChildren( NULL, TRUE /* only this handler */,
GetParamNode(_T("content")));
CreateChildrenPrivately(NULL, GetParamNode(_T("content")));
wxString *strings = (wxString *) NULL;
if( strList.GetCount() > 0 )
{
@@ -64,7 +63,7 @@ wxObject *wxCheckListXmlHandler::DoCreateResource()
while (n)
{
if (n->GetType() != wxXML_ELEMENT_NODE ||
n->GetName() != _T("item" ))
n->GetName() != _T("item"))
{ n = n->GetNext(); continue; }
// checking boolean is a bit ugly here (see GetBool() )
@@ -102,10 +101,9 @@ wxObject *wxCheckListXmlHandler::DoCreateResource()
bool wxCheckListXmlHandler::CanHandle(wxXmlNode *node)
{
return( node->GetName() == _T("checklist") ||
( m_InsideBox &&
node->GetName() == _T("item" ))
);
return (IsOfClass(node, _T("wxCheckList")) ||
(m_InsideBox && node->GetName() == _T("item"))
);
}