mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
Hooks the component fields back into the inspector so they are registered as proper fields of their types, as opposed to the regular string-only dynamic fields.
This commit is contained in:
parent
2464b620ba
commit
89672ea0ab
8 changed files with 369 additions and 9 deletions
|
|
@ -32,6 +32,7 @@
|
|||
#ifdef TORQUE_EXPERIMENTAL_EC
|
||||
#include "gui/editor/inspector/entityGroup.h"
|
||||
#include "gui/editor/inspector/mountingGroup.h"
|
||||
#include "gui/editor/inspector/componentGroup.h"
|
||||
#endif
|
||||
|
||||
IMPLEMENT_CONOBJECT(GuiInspector);
|
||||
|
|
@ -609,6 +610,17 @@ void GuiInspector::refresh()
|
|||
addObject(mounting);
|
||||
}
|
||||
}
|
||||
|
||||
if (mTargets.first()->getClassRep()->isSubclassOf("Component"))
|
||||
{
|
||||
//Build the component field groups as the component describes it
|
||||
Component* comp = dynamic_cast<Component*>(mTargets.first().getPointer());
|
||||
|
||||
GuiInspectorComponentGroup *compGroup = new GuiInspectorComponentGroup("Component Fields", this);
|
||||
compGroup->registerObject();
|
||||
mGroups.push_back(compGroup);
|
||||
addObject(compGroup);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Create the inspector groups for static fields.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue