mirror of
https://github.com/kevinporetti/UnrealImGui.git
synced 2025-01-18 16:30:32 +00:00
09572a8ef9
- Divided ImGui settings into UImGuiSettings persistent object and FImGuiModuleSettings proxy that provides interface for other classes and handles delayed loading of UImGuiSettings. - Removed from FImGuiModuleProperties and FImGuiModuleCommands direct dependencies on UImGuiSettings. - Simplified FImGuiModuleProperties making it more robust when moving data after hot-reloading. - Inverted binding logic by injecting FImGuiModuleProperties and FImGuiModuleCommands into FImGuiModuleSettings and letting it take care of synchronization. Dependencies are setup by module manager. - Added to module manager FImGuiModuleSettings and interface to access it. - Cleaned interface of FImGuiInputHandlerFactory and removed direct dependency on settings.
33 lines
560 B
C++
33 lines
560 B
C++
// Distributed under the MIT License (MIT) (see accompanying LICENSE file)
|
|
|
|
#pragma once
|
|
|
|
#include <imgui.h>
|
|
|
|
class FImGuiModuleProperties;
|
|
|
|
// Widget drawing ImGui demo.
|
|
class FImGuiDemo
|
|
{
|
|
public:
|
|
|
|
FImGuiDemo(FImGuiModuleProperties& InProperties)
|
|
: Properties(InProperties)
|
|
{
|
|
}
|
|
|
|
void DrawControls(int32 ContextIndex);
|
|
|
|
private:
|
|
|
|
FImGuiModuleProperties& Properties;
|
|
|
|
ImVec4 ClearColor = ImColor{ 114, 144, 154 };
|
|
|
|
int32 ShowDemoWindowMask = 0;
|
|
int32 ShowAnotherWindowMask = 0;
|
|
|
|
int32 DemoWindowCounter = 0;
|
|
uint32 LastDemoWindowFrameNumber = 0;
|
|
};
|