// Copyright 2025 https://yuewu.dev/en All Rights Reserved. #pragma once #include "CoreMinimal.h" #include "UObject/Object.h" #include "Layout/Visibility.h" #include "IPropertyTypeCustomization.h" class FDetailWidgetRow; class IDetailChildrenBuilder; class IPropertyHandle; /** Details customization for FAttributeBasedFloat */ class GENERICGAMEPLAYABILITIESEDITOR_API FGGA_AttributeGroupNameCustomization : public IPropertyTypeCustomization { public: static TSharedRef MakeInstance(); /** Overridden to provide the property name or hide, if necessary */ virtual void CustomizeHeader(TSharedRef StructPropertyHandle, FDetailWidgetRow& HeaderRow, IPropertyTypeCustomizationUtils& StructCustomizationUtils) override; static void GeneratePrimaryComboboxStrings(TArray>& OutComboBoxStrings, TArray>& OutToolTips, TArray& OutRestrictedItems, bool bAllowClear, bool bAllowAll, TMap>* InItems); FString GenerateMainString(); void OnMainValueSelected(const FString& String); static void GenerateSubComboboxStrings(TArray>& OutComboBoxStrings, TArray>& OutToolTips, TArray& OutRestrictedItems, bool bAllowClear, bool bAllowAll, TMap>* InItems, TSharedPtr PrimaryKey); FString GenerateSubString(); void OnSubValueSelected(const FString& String); /** Overridden to allow for possibly being hidden */ virtual void CustomizeChildren(TSharedRef StructPropertyHandle, IDetailChildrenBuilder& StructBuilder, IPropertyTypeCustomizationUtils& StructCustomizationUtils) override; private: TMap> FNameMap; TSharedPtr MainNamePropertyHandle; TSharedPtr SubNamePropertyHandle; TWeakPtr PropertyUtilities; };