Skip to content

Commit

Permalink
2.10.1192
Browse files Browse the repository at this point in the history
* Exported symbol pass - this should ensure that all required symbols
  are correctly exported for external consumption
* Factored unit tests out into their own editor module to better test
  all required symbols are exported from the primary plugin module
  • Loading branch information
stephenwhittle committed Oct 11, 2021
1 parent 2b03296 commit e9c8ec8
Show file tree
Hide file tree
Showing 81 changed files with 312 additions and 190 deletions.
7 changes: 1 addition & 6 deletions Doc/documentation.html
Original file line number Diff line number Diff line change
Expand Up @@ -892,7 +892,6 @@ <h1>mod.io UE4 Plugin Documentation</h1>
<li><a href="#_modioreportparams">ModioReportParams</a></li>
<li><a href="#_modioterms">ModioTerms</a></li>
<li><a href="#_modiolink">ModioLink</a></li>
<li><a href="#_modiotestfilterparamdata">ModioTestFilterParamData</a></li>
<li><a href="#_modiooptionaluser">ModioOptionalUser</a></li>
<li><a href="#_modiovalidationerror">ModioValidationError</a></li>
</ul>
Expand Down Expand Up @@ -4276,10 +4275,6 @@ <h4 id="_variables_16" class="discrete">Variables</h4>
<hr>
</div>
<div class="sect2">
<h3 id="_modiotestfilterparamdata">ModioTestFilterParamData</h3>
<hr>
</div>
<div class="sect2">
<h3 id="_modiooptionaluser">ModioOptionalUser</h3>
<hr>
</div>
Expand Down Expand Up @@ -5903,7 +5898,7 @@ <h4 id="_values_19" class="discrete">Values</h4>
</div>
<div id="footer">
<div id="footer-text">
Last updated 2021-10-01 13:09:46 +1000
Last updated 2021-10-11 17:07:36 +1100
</div>
</div>
</body>
Expand Down
Binary file modified Doc/img/nd_img_DisableModManagement.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_GetLogoFullSize.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_GetLogoThumbnailSize.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_GetProjectEnvironment.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_IsModManagementBusy.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_K2_GetModDependenciesAsync.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_K2_GetModTagOptionsAsync.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_K2_UnsubscribeFromModAsync.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_ListUserSubscriptionAsync.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_MakeApiKey.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_MakeAuthParams.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Doc/img/nd_img_QueryUserInstallations.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions Modio.uplugin
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
"Name": "Modio",
"Type": "Runtime",
"LoadingPhase": "Default"
},
{
"Name": "ModioTests",
"Type": "Editor",
"LoadingPhase": "Default"
}
]
}
18 changes: 14 additions & 4 deletions Source/Modio/Modio.Build.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,22 +25,30 @@ public Modio(ReadOnlyTargetRules Target) : base(Target)
//Add stub generated header
{
string GeneratedHeaderPath = Path.Combine(ModuleDirectory, "GeneratedHeader");

//Clean the generated source directory so that we dont have any stale files in it
if (Directory.Exists(GeneratedHeaderPath))
{
Directory.Delete(GeneratedHeaderPath, true);
}
Directory.CreateDirectory(GeneratedHeaderPath);

Directory.CreateDirectory(Path.Combine(GeneratedHeaderPath, "Public"));
Directory.CreateDirectory(Path.Combine(GeneratedHeaderPath, "Private"));

//Because this file is a dummy we don't need it as a dependency
string GeneratedHeaderFilePath = Path.Combine(GeneratedHeaderPath, "ModioGeneratedVariables.h");
string GeneratedHeaderFilePath = Path.Combine(GeneratedHeaderPath, "Private", "ModioGeneratedVariables.h");
using (StreamWriter DummyGeneratedHeader = File.AppendText(GeneratedHeaderFilePath))
{ };

// Silly hack/workaround until 4.26 adds ConditionalAddModuleDirectory - we may change where this lives in the native SDK later
string ErrorConditionLibraryPath = Path.Combine(ModuleDirectory, "../ThirdParty/NativeSDK/modio/modio/core/ModioErrorCondition.h");
// Add dependency on the upstream file so if it is modified we re-run and copy it again
ExternalDependencies.Add(ErrorConditionLibraryPath);
File.Copy(ErrorConditionLibraryPath, Path.Combine(GeneratedHeaderPath, "ModioErrorCondition.h"), true);
File.Copy(ErrorConditionLibraryPath, Path.Combine(GeneratedHeaderPath, "Public", "ModioErrorCondition.h"), true);


PublicIncludePaths.AddRange(new string[] {
Path.Combine(GeneratedHeaderPath, "Public")
});

PublicSystemIncludePaths.AddRange(new string[] {
Expand All @@ -59,10 +67,12 @@ public Modio(ReadOnlyTargetRules Target) : base(Target)
Path.Combine(ModuleDirectory, "../ThirdParty/NativeSDK/platform/ms-common/include"),
Path.Combine(ModuleDirectory, "../ThirdParty/NativeSDK/platform/win32/win32"),
Path.Combine(ModuleDirectory, "../ThirdParty/NativeSDK/modio"),
GeneratedHeaderPath
Path.Combine(GeneratedHeaderPath, "Private"),
Path.Combine(GeneratedHeaderPath, "Public")
});
}
// Add native SDK implementation to this module so we don't have to create an extraneous module
// TODO: @modio-ue4 cleanup by using UE_4_26_OR_LATER so we can use ConditionalAddModuleDirectory
{
string GeneratedSourcePath = Path.Combine(ModuleDirectory, "GeneratedSource");

Expand Down
3 changes: 0 additions & 3 deletions Source/Modio/Private/Tests/ToUnreal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@
#include "Engine.h"
#include "Libraries/ModioSDKLibrary.h"
#include "Misc/AutomationTest.h"
#include "Tests/Commands/InitializeAsync.h"
#include "Tests/Commands/ShutdownAsync.h"
#include "Tests/Commands/SubscribeToModAsync.h"
#include "Internal/Convert/ModStats.h"

#if WITH_DEV_AUTOMATION_TESTS
Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioCommonTypesLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@
#include "Types/ModioInitializeOptions.h"
#include "Types/ModioAuthenticationParams.h"

// clang-format off
#include "ModioCommonTypesLibrary.generated.h"
// clang-format on


UCLASS()
class UModioCommonTypesLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioCommonTypesLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()
public:
Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioErrorCodeLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioErrorCode.h"

// clang-format off
#include "ModioErrorCodeLibrary.generated.h"
// clang-format on


UCLASS()
class UModioErrorCodeLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioErrorCodeLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()
public:
Expand Down
2 changes: 1 addition & 1 deletion Source/Modio/Public/Libraries/ModioErrorConditionLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@


UCLASS()
class UModioErrorConditionLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioErrorConditionLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioFilterParamsLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,11 @@

#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioFilterParams.h"
// clang-format on

#include "ModioFilterParamsLibrary.generated.h"
// clang-format off

UCLASS()
class UModioFilterParamsLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioFilterParamsLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioImageLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,13 @@
#include "Types/ModioImage.h"
#include "Types/ModioImageState.h"

// clang-format off
#include "ModioImageLibrary.generated.h"
// clang-format on


DECLARE_DYNAMIC_DELEGATE_OneParam(FOnLoadImageDelegate, class UTexture2DDynamic*, Texture);

UCLASS()
class UModioImageLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioImageLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()
public:
Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioModCollectionLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioModCollectionEntry.h"

// clang-format off
#include "ModioModCollectionLibrary.generated.h"
// clang-format on


UCLASS()
class UModioModCollectionLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioModCollectionLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()
public:
Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioModDependenciesLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioModDependencyList.h"

// clang-format off
#include "ModioModDependenciesLibrary.generated.h"
// clang-format on


UCLASS()
class UModioModDependenciesLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioModDependenciesLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioModInfoListLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioModInfoList.h"

// clang-format off
#include "ModioModInfoListLibrary.generated.h"
// clang-format on


UCLASS()
class UModioModInfoListLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioModInfoListLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioModTagOptionsLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
#include "Kismet/BlueprintFunctionLibrary.h"
#include "Types/ModioModTagOptions.h"

// clang-format off
#include "ModioModTagOptionsLibrary.generated.h"
// clang-format on


UCLASS()
class UModioModTagOptionsLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioModTagOptionsLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
5 changes: 2 additions & 3 deletions Source/Modio/Public/Libraries/ModioOptionalLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,11 @@
#include "Types/ModioImage.h"
#include "Types/ModioModDependencyList.h"

// clang-format off
#include "ModioOptionalLibrary.generated.h"
// clang-format on


UCLASS()
class UModioOptionalLibrary : public UBlueprintFunctionLibrary
class MODIO_API UModioOptionalLibrary : public UBlueprintFunctionLibrary
{
GENERATED_BODY()

Expand Down
3 changes: 1 addition & 2 deletions Source/Modio/Public/Libraries/ModioSDKLibrary.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,8 @@
#include "Types/ModioInitializeOptions.h"
#include "Types/ModioCommonTypes.h"

// clang-format off
#include "ModioSDKLibrary.generated.h"
// clang-format on


UENUM(BlueprintType)
enum EFileSizeUnit
Expand Down
16 changes: 0 additions & 16 deletions Source/Modio/Public/ModioSDK.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,6 @@

#pragma once

//#if PLATFORM_WINDOWS
// // clang-format off
// #include "Windows/AllowWindowsPlatformTypes.h"
// #include "Windows/PreWindowsApi.h"
// #include "Windows/AllowWindowsPlatformAtomics.h"
//// clang-format on
//#endif

#define MODIO_PLATFORM_UNREAL 1

#pragma push_macro("check")
Expand All @@ -39,11 +31,3 @@
#pragma warning(pop)

#pragma pop_macro("check")

//#if PLATFORM_WINDOWS
// // clang-format off
// #include "Windows/PostWindowsApi.h"
// #include "Windows/HideWindowsPlatformTypes.h"
// #include "Windows/HideWindowsPlatformAtomics.h"
// // clang-format on
//#endif
2 changes: 1 addition & 1 deletion Source/Modio/Public/ModioSettings.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

/** @brief Settings that can be configured per project that generally don't change during the run of a game */
UCLASS(Config = Game, defaultconfig)
class UModioSettings : public UObject
class MODIO_API UModioSettings : public UObject
{
GENERATED_BODY()
public:
Expand Down
8 changes: 4 additions & 4 deletions Source/Modio/Public/ModioSubsystem.h
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ class UModioSubsystem : public UEngineSubsystem
* @param OnInitComplete Callback which will be invoked with the result of initialization
*/
UFUNCTION(BlueprintCallable, DisplayName = "InitializeAsync", Category = "mod.io")
void K2_InitializeAsync(const FModioInitializeOptions& InitializeOptions, FOnErrorOnlyDelegate OnInitComplete);
MODIO_API void K2_InitializeAsync(const FModioInitializeOptions& InitializeOptions, FOnErrorOnlyDelegate OnInitComplete);

/**
* @brief Sends a request to the Mod.io server to add the specified mod to the user's list of subscriptions, and
Expand All @@ -482,14 +482,14 @@ class UModioSubsystem : public UEngineSubsystem
* @param OnSubscribeComplete Callback invoked when the subscription request is completed.
**/
UFUNCTION(BlueprintCallable, DisplayName = "SubscribeToModAsync", Category = "mod.io|Mods")
void K2_SubscribeToModAsync(FModioModID ModToSubscribeTo, FOnErrorOnlyDelegate OnSubscribeComplete);
MODIO_API void K2_SubscribeToModAsync(FModioModID ModToSubscribeTo, FOnErrorOnlyDelegate OnSubscribeComplete);

/**
* @brief Cancels any running internal operations, frees SDK resources, and invokes any pending callbacks with
* Modio::GenericError::OperationCanceled . This function will NOT block while the deinitialization occurs.
**/
UFUNCTION(BlueprintCallable, DisplayName = "ShutdownAsync", Category = "mod.io")
void K2_ShutdownAsync(FOnErrorOnlyDelegate OnShutdownComplete);
MODIO_API void K2_ShutdownAsync(FOnErrorOnlyDelegate OnShutdownComplete);

/**
* @brief Sends a request to the Mod.io server to remove the specified mod from the user's list of subscriptions.
Expand Down Expand Up @@ -559,7 +559,7 @@ class UModioSubsystem : public UEngineSubsystem
* @error GenericError::SDKNotInitialized|SDK not initialized
*/
UFUNCTION(BlueprintCallable, DisplayName = "ListAllModsAsync", Category = "mod.io|Mods")
void K2_ListAllModsAsync(const FModioFilterParams& Filter, FOnListAllModsDelegate Callback);
MODIO_API void K2_ListAllModsAsync(const FModioFilterParams& Filter, FOnListAllModsDelegate Callback);

/**
* @brief Fetches detailed information about the specified mod, including description and file metadata for the
Expand Down
2 changes: 1 addition & 1 deletion Source/Modio/Public/Types/ModioAuthenticationParams.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ enum class EModioAuthenticationProvider : uint8

/** @brief Simple struct to encapsulate data passed to external authentication systems */
USTRUCT(BlueprintType)
struct FModioAuthenticationParams
struct MODIO_API FModioAuthenticationParams
{
GENERATED_BODY();
UPROPERTY(BlueprintReadWrite, EditInstanceOnly)
Expand Down
Loading

0 comments on commit e9c8ec8

Please sign in to comment.