From 14d099ce37cf49727bd055a992da1eec58fecfc0 Mon Sep 17 00:00:00 2001 From: Areloch Date: Wed, 8 Mar 2023 13:01:52 -0600 Subject: [PATCH] Corrects logic handling the TypeString for the onInspect dynamic field behavior. --- Engine/source/gui/editor/inspector/group.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Engine/source/gui/editor/inspector/group.cpp b/Engine/source/gui/editor/inspector/group.cpp index badc5fce9..75d0460a1 100644 --- a/Engine/source/gui/editor/inspector/group.cpp +++ b/Engine/source/gui/editor/inspector/group.cpp @@ -607,7 +607,16 @@ void GuiInspectorGroup::addInspectorField(StringTableEntry name, StringTableEntr else fieldType = -1; - GuiInspectorField* fieldGui = constructField(fieldType); + GuiInspectorField* fieldGui; + + //Currently the default GuiInspectorField IS the string type, so we'll control + //for that type here. If it's not TypeString, we allow the normal creation process + //to continue + if (fieldType == TypeString) + fieldGui = new GuiInspectorField(); + else + fieldGui = constructField(fieldType); + if (fieldGui == nullptr) { //call down into script and see if there's special handling for that type of field