m_strType.Replace("[]", "*");
m_strType.Replace("long int", "long"); // in wx typically we never write "long int", just "long"
m_strType.Replace("long unsigned int", "unsigned long");
+ m_strType.Replace("short unsigned int", "unsigned short");
// make sure the * and & operator always use the same spacing rules
// (to make sure GetAsString() output is always consistent)
// ADHOC-FIX
m_strType.Replace("_wxArraywxArrayStringBase", "wxString");
+ m_strType.Replace("ExitCode", "void*"); // used in wxThread stuff
m_strType = m_strType.Strip(wxString::both);
// Note: we adjust the aesthetic form of the m_strDefaultValue string for the "modify mode"
// of ifacecheck: we may need to write it out in an interface header
- wxString *p;
+ wxString *p = NULL;
for (int i=0; i<2; i++) // to avoid copying&pasting the code!
{
if (i == 0) p = &m_strDefaultValue;
if (i == 1) p = &m_strDefaultValueForCmp;
- if (*p == "0u") *p = "0";
+ if (*p == "0u" || *p == "0l") *p = "0";
p->Replace("0x000000001", "1");
p->Replace("\\000\\000\\000", ""); // fix for unicode strings:
wxXmlNode *subchild = child->GetChildren();
while (subchild)
{
- wxString kind = subchild->GetAttribute("kind");
-
- // parse only public&protected functions:
- if (subchild->GetName() == "sectiondef" &&
- (kind == "public-func" || kind == "protected-func"))
+ // NOTE: when documenting functions using the //@{ and //@}
+ // tags to create function groups, doxygen puts the
+ // contained methods into a "user-defined" section
+ // so we _must_ use the "prot" attribute to distinguish
+ // public/protected methods from private ones and cannot
+ // rely on the kind="public" attribute of <sectiondef>
+ if (subchild->GetName() == "sectiondef")
{
-
wxXmlNode *membernode = subchild->GetChildren();
while (membernode)
{
+ const wxString& accessSpec = membernode->GetAttribute("prot");
+
+ // parse only public&protected functions:
if (membernode->GetName() == "memberdef" &&
- membernode->GetAttribute("kind") == "function")
+ membernode->GetAttribute("kind") == "function" &&
+ (accessSpec == "public" || accessSpec == "protected"))
{
wxMethod m;
return false;
}
- if (kind == "public-func")
+ if (accessSpec == "public")
m.SetAccessSpecifier(wxMAS_PUBLIC);
- else if (kind == "protected-func")
+ else if (accessSpec == "protected")
m.SetAccessSpecifier(wxMAS_PROTECTED);
- else if (kind == "private-func")
+ else if (accessSpec == "private")
m.SetAccessSpecifier(wxMAS_PRIVATE);
if (absoluteFile.IsEmpty())