MCPcopy Create free account
hub / github.com/MothCocoon/FlowGraph / CreateFlowWidget

Method CreateFlowWidget

Source/FlowEditor/Private/Utils/SLevelEditorFlow.cpp:25–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23}
24
25void SLevelEditorFlow::CreateFlowWidget()
26{
27 if (const UFlowComponent* FlowComponent = FindFlowComponent(); FlowComponent && FlowComponent->RootFlow)
28 {
29 FlowAssetPath = FlowComponent->RootFlow->GetPathName();
30 }
31 else
32 {
33 FlowAssetPath = FString();
34 }
35
36 ChildSlot
37 [
38 SNew(SHorizontalBox)
39 + SHorizontalBox::Slot()
40 .AutoWidth()
41 [
42 SNew(SObjectPropertyEntryBox)
43 .AllowedClass(GetDefault<UFlowGraphSettings>()->WorldAssetClass)
44 .DisplayThumbnail(false)
45 .OnObjectChanged(this, &SLevelEditorFlow::OnFlowChanged)
46 .ObjectPath(this, &SLevelEditorFlow::GetFlowAssetPath) // needs function to automatically refresh view upon data change
47 ]
48 ];
49}
50
51FString SLevelEditorFlow::GetFlowAssetPath() const
52{

Callers

nothing calls this directly

Calls 1

FStringClass · 0.85

Tested by

no test coverage detected