Fixed the application of translation overrides to free standing BehaviorProperty constants

Signed-off-by: lsemp3d <58790905+lsemp3d@users.noreply.github.com>
This commit is contained in:
lsemp3d
2021-11-12 15:45:55 -08:00
parent 4fac65b600
commit 5072c2667f
11 changed files with 155 additions and 26 deletions
@@ -1049,17 +1049,22 @@ namespace ScriptCanvasEditor
if (auto registerIter = m_registeredNodes.find(nodeIdentifier); registerIter == m_registeredNodes.end())
{
auto methodModelInformation = AZStd::make_unique<GlobalMethodNodeModelInformation>();
methodModelInformation->m_methodName = behaviorMethod.m_name;
methodModelInformation->m_nodeIdentifier = nodeIdentifier;
methodModelInformation->m_methodName = behaviorMethod.m_name;
methodModelInformation->m_titlePaletteOverride = "MethodNodeTitlePalette";
AZStd::string name = behaviorProperty->m_name;
AZ::StringFunc::Replace(name, "::Getter", "");
AZ::StringFunc::Replace(name, "::Setter", "");
GraphCanvas::TranslationKey key;
key << "Constant" << behaviorProperty->m_name.c_str() << "details";
key << "Constant" << name << "details";
GraphCanvas::TranslationRequests::Details details;
GraphCanvas::TranslationRequestBus::BroadcastResult(details, &GraphCanvas::TranslationRequests::GetDetails, key, details);
methodModelInformation->m_displayName = details.m_name;
methodModelInformation->m_toolTip = details.m_tooltip;
methodModelInformation->m_categoryPath = details.m_category;