You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
TPS doesn't need SDK and will be used to get info about the platform TPC requires SDK AndroidTP has been converted to the new system #jira UE-200883 #rb Jack.Porter [CL 30963905 by florin pascu in 5.4 branch]
66 lines
1.6 KiB
C++
66 lines
1.6 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#pragma once
|
|
|
|
#include "CoreMinimal.h"
|
|
#include "Modules/ModuleInterface.h"
|
|
#include "Interfaces/ITargetPlatform.h"
|
|
#include "Interfaces/ITargetPlatformSettings.h"
|
|
|
|
|
|
class ITargetPlatformControlsModule;
|
|
class ITargetPlatformSettingsModule;
|
|
class ITargetPlatformControls;
|
|
/**
|
|
* Interface for target platform modules.
|
|
*/
|
|
class ITargetPlatformModule
|
|
: public IModuleInterface
|
|
{
|
|
|
|
public:
|
|
|
|
/** Virtual destructor. */
|
|
virtual ~ITargetPlatformModule()
|
|
{
|
|
for (ITargetPlatform* TP : AllTargetPlatforms)
|
|
{
|
|
delete TP;
|
|
}
|
|
AllTargetPlatforms.Empty();
|
|
}
|
|
|
|
/**
|
|
* Gets the module's target platforms. This should be overridden by each platform, but
|
|
* currently, we are re-using the single internal GetTargetPlatform method the old TPModules will implement
|
|
*
|
|
* @return The target platform.
|
|
*/
|
|
TArray<ITargetPlatform*> GetTargetPlatforms()
|
|
{
|
|
if (AllTargetPlatforms.Num() == 0)
|
|
{
|
|
GetTargetPlatforms(AllTargetPlatforms, PlatformSettings, PlatformControls);
|
|
}
|
|
|
|
return AllTargetPlatforms;
|
|
}
|
|
|
|
TArray<ITargetPlatformSettings*> PlatformSettings;
|
|
TArray<ITargetPlatformControls*> PlatformControls;
|
|
|
|
protected:
|
|
|
|
/**
|
|
* This is where each platform module will fill out an array
|
|
*/
|
|
virtual void GetTargetPlatforms(TArray<ITargetPlatform*>& TargetPlatforms) = 0;
|
|
virtual void GetTargetPlatforms(TArray<ITargetPlatform*>& TargetPlatforms, TArray<ITargetPlatformSettings*> TargetPlatformSettings, TArray<ITargetPlatformControls*> TargetPlatformControls)
|
|
{
|
|
GetTargetPlatforms(TargetPlatforms);
|
|
}
|
|
private:
|
|
/** Holds the target platforms. */
|
|
TArray<ITargetPlatform*> AllTargetPlatforms;
|
|
};
|