Skip to content

Commit

Permalink
...
Browse files Browse the repository at this point in the history
  • Loading branch information
vczh committed Jul 27, 2020
1 parent 70caef0 commit 43a47d1
Show file tree
Hide file tree
Showing 2 changed files with 628 additions and 6 deletions.
20 changes: 20 additions & 0 deletions Tools/CppDoc/Reflection/Source/ExportReflectableTypes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,26 @@ void LogTypes(Ptr<XmlElement> xmlRoot, const WString& projectName, SortedList<WS
auto attr = MakePtr<XmlAttribute>();
attr->name.value = L"name";
attr->value.value = projectName;
xmlProject->attributes.Add(attr);
}

vint count = GetGlobalTypeManager()->GetTypeDescriptorCount();
for (vint i = 0; i < count; i++)
{
auto td = GetGlobalTypeManager()->GetTypeDescriptor(i);
WString tdName = td->GetTypeName();
if (loaded.Contains(tdName)) continue;
loaded.Add(tdName);

auto xmlType = MakePtr<XmlElement>();
xmlType->name.value = L"type";
xmlProject->subNodes.Add(xmlType);
{
auto attr = MakePtr<XmlAttribute>();
attr->name.value = L"registered";
attr->value.value = tdName;
xmlType->attributes.Add(attr);
}
}
}

Expand Down
Loading

0 comments on commit 43a47d1

Please sign in to comment.