You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
UMG/Slate - Exposing the Widget Caching flag to the widget reflector. Also making it so invalidation is disabled when Picking Widgets is occuring, as invalidation causes that system of traversing the widget hierarchy to no longer function. Since it pretends there are no children to avoid Slate doing more work than it needs to.
[CL 2695558 by Nick Darnell in Main branch]
This commit is contained in:
committed by
Nick.Darnell@epicgames.com
parent
6ae67a3bea
commit
4181457d07
@@ -210,6 +210,11 @@ private:
|
||||
{
|
||||
bShowFocus = false;
|
||||
SetUIMode(EWidgetReflectorUIMode::Live);
|
||||
SInvalidationPanel::SetEnableWidgetCaching(false);
|
||||
}
|
||||
else
|
||||
{
|
||||
SInvalidationPanel::SetEnableWidgetCaching(true);
|
||||
}
|
||||
|
||||
return FReply::Handled();
|
||||
@@ -611,6 +616,31 @@ TSharedRef<SDockTab> SWidgetReflector::SpawnWidgetHierarchyTab(const FSpawnTabAr
|
||||
SNew(STextBlock)
|
||||
.Text(LOCTEXT("ShowFocus", "Show Focus"))
|
||||
]
|
||||
|
||||
+ SHorizontalBox::Slot()
|
||||
.AutoWidth()
|
||||
.Padding(5.0f)
|
||||
[
|
||||
SNew(SCheckBox)
|
||||
.Style(FCoreStyle::Get(), "ToggleButtonCheckbox")
|
||||
.IsChecked_Lambda([&]()
|
||||
{
|
||||
return SInvalidationPanel::GetEnableWidgetCaching() ? ECheckBoxState::Checked : ECheckBoxState::Unchecked;
|
||||
})
|
||||
.OnCheckStateChanged_Lambda([&](const ECheckBoxState NewState)
|
||||
{
|
||||
SInvalidationPanel::SetEnableWidgetCaching(( NewState == ECheckBoxState::Checked ) ? true : false);
|
||||
})
|
||||
[
|
||||
SNew(SBox)
|
||||
.VAlign(VAlign_Center)
|
||||
.HAlign(HAlign_Center)
|
||||
[
|
||||
SNew(STextBlock)
|
||||
.Text(LOCTEXT("EnableWidgetCaching", "Widget Caching"))
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
||||
|
||||
+SHorizontalBox::Slot()
|
||||
|
||||
Reference in New Issue
Block a user