fix for edit SC action in entity context menu (#6686)
* on demand reflect az events when they are the return value of ebuses Signed-off-by: carlitosan <82187351+carlitosan@users.noreply.github.com> * fix crash and functionality for edit sc editor context menu action Signed-off-by: carlitosan <82187351+carlitosan@users.noreply.github.com>
This commit is contained in:
@@ -265,11 +265,13 @@ namespace ScriptCanvasEditor
|
||||
|
||||
action = entityMenu->addAction(QString("%1").arg(QString(displayName.c_str())));
|
||||
|
||||
QObject::connect(action, &QAction::triggered, [assetId]
|
||||
QObject::connect(action, &QAction::triggered, [assetInfo]
|
||||
{
|
||||
AzToolsFramework::OpenViewPane(LyViewPane::ScriptCanvas);
|
||||
SourceHandle sourceHandle(nullptr, assetInfo.m_assetId.m_guid, "");
|
||||
CompleteDescriptionInPlace(sourceHandle);
|
||||
GeneralRequestBus::Broadcast(&GeneralRequests::OpenScriptCanvasAsset
|
||||
, SourceHandle(nullptr, assetId.m_guid, "")
|
||||
, sourceHandle
|
||||
, Tracker::ScriptCanvasFileState::UNMODIFIED, -1);
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user