|
@@ -5,7 +5,9 @@
|
|
|
#include "SlateOptMacros.h"
|
|
|
#include "SAbleTreeExpanderArrow.h"
|
|
|
#include "AbleTreeEditorStyle.h"
|
|
|
-
|
|
|
+#include "Styling/SlateTypes.h"
|
|
|
+#include "Widgets/Text/SInlineEditableTextBlock.h"
|
|
|
+
|
|
|
|
|
|
#define LOCTEXT_NAMESPACE "AbleTreeViewRow"
|
|
|
BEGIN_SLATE_FUNCTION_BUILD_OPTIMIZATION
|
|
@@ -126,7 +128,7 @@ void SEzAbleTreeViewRowWidget::Construct(const FArguments& InArgs, const TShared
|
|
|
.BaseIndentLevel(0)
|
|
|
.ImageSize(FVector2f(16, 16))
|
|
|
.ImagePadding(FMargin(9, 14, 0, 0))
|
|
|
- .Image(this, &SEzAbleTreeViewRowWidget::GetSelectorIcon)
|
|
|
+ .Image(FAbleTreeEditorStyle::Get().GetBrush("StateTreeEditor.TryFollowTransitions"))
|
|
|
.ColorAndOpacity(FLinearColor(1, 1, 1, 0.2f))
|
|
|
.WireColorAndOpacity(FLinearColor(1, 1, 1, 0.2f))
|
|
|
]
|
|
@@ -161,11 +163,11 @@ void SEzAbleTreeViewRowWidget::Construct(const FArguments& InArgs, const TShared
|
|
|
[
|
|
|
SNew(SBorder)
|
|
|
.BorderImage(FAbleTreeEditorStyle::Get().GetBrush("StateTree.State.Border"))
|
|
|
-
|
|
|
+ .BorderBackgroundColor(FLinearColor(FColor(236, 134, 39)))
|
|
|
[
|
|
|
SNew(SBorder)
|
|
|
.BorderImage(FAbleTreeEditorStyle::Get().GetBrush("StateTree.State"))
|
|
|
-
|
|
|
+ .BorderBackgroundColor(FLinearColor(FColor(31, 151, 167)))
|
|
|
.Padding(FMargin(0.f, 0.f, 12.f, 0.f))
|
|
|
.IsEnabled_Lambda([InState]
|
|
|
{
|
|
@@ -222,7 +224,7 @@ void SEzAbleTreeViewRowWidget::Construct(const FArguments& InArgs, const TShared
|
|
|
.Padding(FMargin(4.f, 0.f, 0.f, 0.f))
|
|
|
[
|
|
|
SNew(SImage)
|
|
|
-
|
|
|
+ .Image(FAbleTreeEditorStyle::Get().GetBrush("StateTreeEditor.SelectNone"))
|
|
|
.ColorAndOpacity(IconTint)
|
|
|
|
|
|
]
|
|
@@ -247,16 +249,16 @@ void SEzAbleTreeViewRowWidget::Construct(const FArguments& InArgs, const TShared
|
|
|
+ SHorizontalBox::Slot()
|
|
|
.VAlign(VAlign_Center)
|
|
|
.AutoWidth()
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+ [
|
|
|
+ SAssignNew(NameTextBlock, SInlineEditableTextBlock)
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ .Text(FText::FromName(FName(TEXT("AbleTree"))))
|
|
|
+
|
|
|
+ .Clipping(EWidgetClipping::ClipToBounds)
|
|
|
+
|
|
|
+ ]
|
|
|
|
|
|
|
|
|
+ SHorizontalBox::Slot()
|
|
@@ -461,8 +463,7 @@ const FSlateBrush* SEzAbleTreeViewRowWidget::GetSelectorIcon() const
|
|
|
{
|
|
|
if (const UEzAbilityState* State = WeakState.Get())
|
|
|
{
|
|
|
- FSlateBrush* SlateBrush = new FSlateBrush();
|
|
|
- return SlateBrush;
|
|
|
+ return FAbleTreeEditorStyle::GetBrushForSelectionBehaviorType();
|
|
|
|
|
|
}
|
|
|
|