23 lines
897 B
C++
23 lines
897 B
C++
#include "ProjectEleriEditorModule.h"
|
|
#include "Modules/ModuleManager.h"
|
|
#include "PropertyEditorModule.h"
|
|
#include "ItemDataAssetCustomization.h"
|
|
|
|
IMPLEMENT_GAME_MODULE(FProjectEleriEditorModule, ProjectEleriEditor);
|
|
|
|
void FProjectEleriEditorModule::StartupModule()
|
|
{
|
|
FPropertyEditorModule& PropEd = FModuleManager::LoadModuleChecked<FPropertyEditorModule>("PropertyEditor");
|
|
PropEd.RegisterCustomClassLayout(
|
|
TEXT("ItemDataAsset"), // UCLASS name
|
|
FOnGetDetailCustomizationInstance::CreateStatic(&FItemDataAssetCustomization::MakeInstance)
|
|
);
|
|
}
|
|
|
|
void FProjectEleriEditorModule::ShutdownModule()
|
|
{
|
|
if (FModuleManager::Get().IsModuleLoaded("PropertyEditor")) {
|
|
FPropertyEditorModule& PropEd = FModuleManager::GetModuleChecked<FPropertyEditorModule>("PropertyEditor");
|
|
PropEd.UnregisterCustomClassLayout(TEXT("ItemDataAsset"));
|
|
}
|
|
} |