mirror of
https://github.com/kevinporetti/UnrealImGui.git
synced 2025-01-18 00:10:32 +00:00
Fixed warnings from Unreal 5.0 Preview 1
This commit is contained in:
parent
7b055e4040
commit
14749e50bb
@ -16,7 +16,7 @@
|
||||
"Modules": [
|
||||
{
|
||||
"Name": "ImGui",
|
||||
"Type": "Developer",
|
||||
"Type": "DeveloperTool",
|
||||
"LoadingPhase": "PreDefault"
|
||||
}
|
||||
]
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include <InputCoreTypes.h>
|
||||
|
||||
|
||||
UImGuiInputHandler* FImGuiInputHandlerFactory::NewHandler(const FStringClassReference& HandlerClassReference, FImGuiModuleManager* ModuleManager, UGameViewportClient* GameViewport, int32 ContextIndex)
|
||||
UImGuiInputHandler* FImGuiInputHandlerFactory::NewHandler(const FSoftClassPath& HandlerClassReference, FImGuiModuleManager* ModuleManager, UGameViewportClient* GameViewport, int32 ContextIndex)
|
||||
{
|
||||
UClass* HandlerClass = nullptr;
|
||||
if (HandlerClassReference.IsValid())
|
||||
|
@ -13,7 +13,7 @@ class FImGuiInputHandlerFactory
|
||||
{
|
||||
public:
|
||||
|
||||
static UImGuiInputHandler* NewHandler(const FStringClassReference& HandlerClassReference, FImGuiModuleManager* ModuleManager, UGameViewportClient* GameViewport, int32 ContextIndex);
|
||||
static UImGuiInputHandler* NewHandler(const FSoftClassPath& HandlerClassReference, FImGuiModuleManager* ModuleManager, UGameViewportClient* GameViewport, int32 ContextIndex);
|
||||
|
||||
static void ReleaseHandler(UImGuiInputHandler* Handler);
|
||||
};
|
||||
|
@ -128,7 +128,7 @@ void FImGuiModuleSettings::UpdateDPIScaleInfo()
|
||||
}
|
||||
}
|
||||
|
||||
void FImGuiModuleSettings::SetImGuiInputHandlerClass(const FStringClassReference& ClassReference)
|
||||
void FImGuiModuleSettings::SetImGuiInputHandlerClass(const FSoftClassPath& ClassReference)
|
||||
{
|
||||
if (ImGuiInputHandlerClass != ClassReference)
|
||||
{
|
||||
|
@ -10,7 +10,7 @@
|
||||
#include <Styling/SlateTypes.h>
|
||||
#include <UObject/Object.h>
|
||||
|
||||
// We use FStringClassReference, which is supported by older and newer engine versions. Starting from 4.18, it is
|
||||
// We use FSoftClassPath, which is supported by older and newer engine versions. Starting from 4.18, it is
|
||||
// a typedef of FSoftClassPath, which is also recognized by UHT.
|
||||
#if ENGINE_COMPATIBILITY_LEGACY_STRING_CLASS_REF
|
||||
#include <StringClassReference.h>
|
||||
@ -176,7 +176,7 @@ protected:
|
||||
// Path to own implementation of ImGui Input Handler allowing to customize handling of keyboard and gamepad input.
|
||||
// If not set then default handler is used.
|
||||
UPROPERTY(EditAnywhere, config, Category = "Extensions", meta = (MetaClass = "ImGuiInputHandler"))
|
||||
FStringClassReference ImGuiInputHandlerClass;
|
||||
FSoftClassPath ImGuiInputHandlerClass;
|
||||
|
||||
// Whether ImGui should share keyboard input with game.
|
||||
// This defines initial behaviour which can be later changed using 'ImGui.ToggleKeyboardInputSharing' command or
|
||||
@ -236,7 +236,7 @@ public:
|
||||
|
||||
// Generic delegate used to notify changes of boolean properties.
|
||||
DECLARE_MULTICAST_DELEGATE_OneParam(FBoolChangeDelegate, bool);
|
||||
DECLARE_MULTICAST_DELEGATE_OneParam(FStringClassReferenceChangeDelegate, const FStringClassReference&);
|
||||
DECLARE_MULTICAST_DELEGATE_OneParam(FStringClassReferenceChangeDelegate, const FSoftClassPath&);
|
||||
DECLARE_MULTICAST_DELEGATE_OneParam(FImGuiCanvasSizeInfoChangeDelegate, const FImGuiCanvasSizeInfo&);
|
||||
DECLARE_MULTICAST_DELEGATE_OneParam(FImGuiDPIScaleInfoChangeDelegate, const FImGuiDPIScaleInfo&);
|
||||
|
||||
@ -253,7 +253,7 @@ public:
|
||||
// event that are defined depending on needs.
|
||||
|
||||
// Get the path to custom implementation of ImGui Input Handler.
|
||||
const FStringClassReference& GetImGuiInputHandlerClass() const { return ImGuiInputHandlerClass; }
|
||||
const FSoftClassPath& GetImGuiInputHandlerClass() const { return ImGuiInputHandlerClass; }
|
||||
|
||||
// Get the software cursor configuration.
|
||||
bool UseSoftwareCursor() const { return bUseSoftwareCursor; }
|
||||
@ -285,7 +285,7 @@ private:
|
||||
void UpdateSettings();
|
||||
void UpdateDPIScaleInfo();
|
||||
|
||||
void SetImGuiInputHandlerClass(const FStringClassReference& ClassReference);
|
||||
void SetImGuiInputHandlerClass(const FSoftClassPath& ClassReference);
|
||||
void SetShareKeyboardInput(bool bShare);
|
||||
void SetShareGamepadInput(bool bShare);
|
||||
void SetShareMouseInput(bool bShare);
|
||||
@ -301,7 +301,7 @@ private:
|
||||
FImGuiModuleProperties& Properties;
|
||||
FImGuiModuleCommands& Commands;
|
||||
|
||||
FStringClassReference ImGuiInputHandlerClass;
|
||||
FSoftClassPath ImGuiInputHandlerClass;
|
||||
FImGuiKeyInfo ToggleInputKey;
|
||||
FImGuiCanvasSizeInfo CanvasSize;
|
||||
FImGuiDPIScaleInfo DPIScale;
|
||||
|
@ -275,7 +275,7 @@ FReply SImGuiWidget::OnTouchEnded(const FGeometry& MyGeometry, const FPointerEve
|
||||
return InputHandler->OnTouchEnded(TransformScreenPointToImGui(MyGeometry, TouchEvent.GetScreenSpacePosition()), TouchEvent);
|
||||
}
|
||||
|
||||
void SImGuiWidget::CreateInputHandler(const FStringClassReference& HandlerClassReference)
|
||||
void SImGuiWidget::CreateInputHandler(const FSoftClassPath& HandlerClassReference)
|
||||
{
|
||||
ReleaseInputHandler();
|
||||
|
||||
|
@ -84,7 +84,7 @@ public:
|
||||
|
||||
private:
|
||||
|
||||
void CreateInputHandler(const FStringClassReference& HandlerClassReference);
|
||||
void CreateInputHandler(const FSoftClassPath& HandlerClassReference);
|
||||
void ReleaseInputHandler();
|
||||
|
||||
void RegisterImGuiSettingsDelegates();
|
||||
|
Loading…
Reference in New Issue
Block a user