You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
34 lines
1.1 KiB
C++
34 lines
1.1 KiB
C++
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
|
|
#include "WindowsMixedRealityRuntimeSettings.h"
|
|
#include "Misc/ConfigCacheIni.h"
|
|
#include "CoreGlobals.h"
|
|
#include "UObject/Package.h"
|
|
|
|
UWindowsMixedRealityRuntimeSettings* UWindowsMixedRealityRuntimeSettings::WMRSettingsSingleton = nullptr;
|
|
|
|
#if WITH_EDITOR
|
|
|
|
void UWindowsMixedRealityRuntimeSettings::PostEditChangeProperty(struct FPropertyChangedEvent& PropertyChangedEvent)
|
|
{
|
|
GConfig->Flush(false);
|
|
}
|
|
|
|
#endif
|
|
|
|
UWindowsMixedRealityRuntimeSettings* UWindowsMixedRealityRuntimeSettings::Get()
|
|
{
|
|
if (WMRSettingsSingleton == nullptr)
|
|
{
|
|
static const TCHAR* SettingsContainerName = TEXT("WindowsMixedRealityRuntimeSettingsContainer");
|
|
|
|
WMRSettingsSingleton = FindObject<UWindowsMixedRealityRuntimeSettings>(GetTransientPackage(), SettingsContainerName);
|
|
|
|
if (WMRSettingsSingleton == nullptr)
|
|
{
|
|
WMRSettingsSingleton = NewObject<UWindowsMixedRealityRuntimeSettings>(GetTransientPackage(), UWindowsMixedRealityRuntimeSettings::StaticClass(), SettingsContainerName);
|
|
WMRSettingsSingleton->AddToRoot();
|
|
}
|
|
}
|
|
return WMRSettingsSingleton;
|
|
} |