Files
UnrealEngineUWP/Engine/Source/Editor/DetailCustomizations/Private/EnvQueryParamInstanceCustomization.h
Ben Marsh 149375b14b Update copyright notices to 2015.
[CL 2379638 by Ben Marsh in Main branch]
2014-12-07 19:09:38 -05:00

43 lines
1.4 KiB
C++

// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "EnvironmentQuery/EnvQueryTypes.h"
class FEnvQueryParamInstanceCustomization : public IPropertyTypeCustomization
{
public:
static TSharedRef<IPropertyTypeCustomization> MakeInstance( );
public:
// IPropertyTypeCustomization interface
virtual void CustomizeHeader( TSharedRef<class IPropertyHandle> StructPropertyHandle, class FDetailWidgetRow& HeaderRow, IPropertyTypeCustomizationUtils& StructCustomizationUtils ) override;
virtual void CustomizeChildren( TSharedRef<class IPropertyHandle> StructPropertyHandle, class IDetailChildrenBuilder& StructBuilder, IPropertyTypeCustomizationUtils& StructCustomizationUtils ) override;
protected:
TSharedPtr<IPropertyHandle> NameProp;
TSharedPtr<IPropertyHandle> ValueProp;
TSharedPtr<IPropertyHandle> TypeProp;
TOptional<float> GetParamNumValue() const;
void OnParamNumValueChanged(float FloatValue) const;
EVisibility GetParamNumValueVisibility() const;
ESlateCheckBoxState::Type GetParamBoolValue() const;
void OnParamBoolValueChanged(ESlateCheckBoxState::Type BoolValue) const;
EVisibility GetParamBoolValueVisibility() const;
FString GetHeaderDesc() const;
void OnTypeChanged();
void InitCachedTypes();
EEnvQueryParam::Type ParamType;
mutable uint8 CachedBool : 1;
mutable float CachedFloat;
mutable int32 CachedInt;
};