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

Method Refresh

Source/FlowEditor/Private/Graph/Widgets/SFlowPalette.cpp:160–182  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

158}
159
160void SFlowPalette::Refresh()
161{
162 const FString LastSelectedCategory = CategoryComboBox->GetSelectedItem().IsValid() ? *CategoryComboBox->GetSelectedItem().Get() : FString();
163
164 UpdateCategoryNames();
165 RefreshActionsList(true);
166
167 // refresh list of category and currently selected category
168 CategoryComboBox->RefreshOptions();
169 TSharedPtr<FString> SelectedCategory = CategoryNames[0];
170 if (!LastSelectedCategory.IsEmpty())
171 {
172 for (const TSharedPtr<FString>& CategoryName : CategoryNames)
173 {
174 if (*CategoryName.Get() == LastSelectedCategory)
175 {
176 SelectedCategory = CategoryName;
177 break;
178 }
179 }
180 }
181 CategoryComboBox->SetSelectedItem(SelectedCategory);
182}
183
184void SFlowPalette::UpdateCategoryNames()
185{

Callers

nothing calls this directly

Calls 4

FStringClass · 0.85
IsValidMethod · 0.80
GetMethod · 0.80
IsEmptyMethod · 0.80

Tested by

no test coverage detected