fixed build against wx3.1.7 Origin: https://github.com/eranif/codelite/commit/427af358d (Trimmed to only fix the build failure) --- a/wxcrafter/myxh_propgrid.cpp 2022-04-18 07:09:00.000000000 +0200 +++ b/wxcrafter/myxh_propgrid.cpp 2022-08-25 09:22:55.219559527 +0200 @@ -1,4 +1,5 @@ #include "myxh_propgrid.h" + #include #include #include @@ -48,10 +49,14 @@ // add the splitter property after the children were added int splitterLeft = GetBool("splitterleft"); - if(splitterLeft) { m_pgmgr->GetPage(0)->SetSplitterLeft(); } + if(splitterLeft) { + m_pgmgr->SetSplitterLeft(); + } int splitterPos = GetLong("splitterpos", wxNOT_FOUND); - if(splitterPos != wxNOT_FOUND) { m_pgmgr->GetPage(0)->SetSplitterPosition(splitterPos); } + if(splitterPos != wxNOT_FOUND) { + m_pgmgr->GetPage(0)->SetSplitterPosition(splitterPos); + } m_isInside = false; return m_pgmgr; @@ -67,7 +72,9 @@ void MyWxPropGridXmlHandler::HandlePgProperty(wxPGProperty* parent) { - if(!HasParam(wxT("proptype"))) { return; } + if(!HasParam(wxT("proptype"))) { + return; + } // Property wxString proptype = GetText("proptype"); @@ -116,7 +123,9 @@ } else if(proptype == "wxEnumProperty") { int sel = items.Index(value); - if(sel == wxNOT_FOUND) { sel = 0; } + if(sel == wxNOT_FOUND) { + sel = 0; + } prop = DoAppendProperty(parent, new wxEnumProperty(label, wxPG_LABEL, items, wxArrayInt(), sel)); @@ -143,8 +152,12 @@ // Handle nested children if(prop) { - if(bgcol.IsOk()) { prop->SetBackgroundColour(bgcol, bgcolRecurse); } - if(!propEditor.IsEmpty()) { prop->SetEditor(propEditor); } + if(bgcol.IsOk()) { + prop->SetBackgroundColour(bgcol, bgcolRecurse); + } + if(!propEditor.IsEmpty()) { + prop->SetEditor(propEditor); + } prop->SetHelpString(tip); // Check to see if this property has children @@ -160,12 +173,15 @@ wxArrayString MyWxPropGridXmlHandler::GetArray(const wxXmlNode* node) const { - if(!node) return wxArrayString(); + if(!node) + return wxArrayString(); wxArrayString items; wxXmlNode* child = node->GetChildren(); while(child) { - if(child->GetName() == "item") { items.Add(child->GetNodeContent()); } + if(child->GetName() == "item") { + items.Add(child->GetNodeContent()); + } child = child->GetNext(); } return items;