unitysamples / LyraStarterGame /Plugins /GameSettings /Source /Public /Widgets /Misc /GameSettingPressAnyKey.h
| // Copyright Epic Games, Inc. All Rights Reserved. | |
| struct FKey; | |
| class UObject; | |
| /** | |
| * | |
| */ | |
| UCLASS(MinimalAPI, Abstract) | |
| class UGameSettingPressAnyKey : public UCommonActivatableWidget | |
| { | |
| GENERATED_BODY() | |
| public: | |
| UE_API UGameSettingPressAnyKey(const FObjectInitializer& Initializer); | |
| DECLARE_EVENT_OneParam(UGameSettingPressAnyKey, FOnKeySelected, FKey); | |
| FOnKeySelected OnKeySelected; | |
| DECLARE_EVENT(UGameSettingPressAnyKey, FOnKeySelectionCanceled); | |
| FOnKeySelectionCanceled OnKeySelectionCanceled; | |
| protected: | |
| UE_API virtual void NativeOnActivated() override; | |
| UE_API virtual void NativeOnDeactivated() override; | |
| UE_API void HandleKeySelected(FKey InKey); | |
| UE_API void HandleKeySelectionCanceled(); | |
| UE_API void Dismiss(TFunction<void()> PostDismissCallback); | |
| private: | |
| bool bKeySelected = false; | |
| TSharedPtr<class FSettingsPressAnyKeyInputPreProcessor> InputProcessor; | |
| }; | |