// Reglages par onglets, et entree Settings de l'ecran titre (entre Mod Manager et Donate). // // Les lignes existent deja dans MainMenu.SettingsScrollBox (cases et curseurs du Blueprint). // Ce sous-systeme ne les recree pas : il les montre ou les cache selon l'onglet. // General, Audio, Video, Keyboard (la liste des touches), Lewd, puis Misc. // Aucun Blueprint n'est modifie. #pragma once #include "CoreMinimal.h" #include "Containers/Ticker.h" #include "Subsystems/GameInstanceSubsystem.h" #include "LPSettingsSubsystem.generated.h" class UButton; class UCanvasPanel; class UHorizontalBox; class UNativeWidgetHost; class UScrollBox; class UTextBlock; class UVerticalBox; class UWidget; UCLASS() class LIFEPLAY_API ULPSettingsSubsystem : public UGameInstanceSubsystem { GENERATED_BODY() public: virtual void Initialize(FSubsystemCollectionBase& Collection) override; virtual void Deinitialize() override; UFUNCTION() void ShowAudio(); UFUNCTION() void ShowVideo(); UFUNCTION() void ShowLewd(); UFUNCTION() void ShowGeneral(); UFUNCTION() void ShowKeyboard(); UFUNCTION() void ShowMisc(); UFUNCTION() void OpenSettings(); private: bool Tick(float DeltaTime); void PlaceSettingsButton(); void EnsureTabs(UScrollBox* Scroll); void SelectTab(int32 Index); void ApplyRows(); FTSTicker::FDelegateHandle TickHandle; int32 ActiveTab = 0; int32 LastChildCount = -1; bool bKeyboardPage = false; bool bControlsHardened = false; TWeakObjectPtr SourceSettings; TWeakObjectPtr OrderedMenu; TWeakObjectPtr SettingsList; TWeakObjectPtr TabBar; TWeakObjectPtr KeyboardHost; TArray> TabLabels; };