You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#jira none #rb sebastian.nordgren #preflight 6295f14f926be5fb68b3e29a [CL 20435453 by George Rolfe in ue5-main branch]
55 lines
1.7 KiB
C++
55 lines
1.7 KiB
C++
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
#include "EditorWidgetsModule.h"
|
|
|
|
#include "EditorWidgetsStyle.h"
|
|
#include "ITransportControl.h"
|
|
#include "ObjectNameEditSinkRegistry.h"
|
|
#include "SAssetDiscoveryIndicator.h"
|
|
#include "SObjectNameEditableTextBox.h"
|
|
#include "STransportControl.h"
|
|
#include "Modules/ModuleManager.h"
|
|
#include "Widgets/DeclarativeSyntaxSupport.h"
|
|
|
|
IMPLEMENT_MODULE( FEditorWidgetsModule, EditorWidgets );
|
|
|
|
const FName FEditorWidgetsModule::EditorWidgetsAppIdentifier( TEXT( "EditorWidgetsApp" ) );
|
|
|
|
void FEditorWidgetsModule::StartupModule()
|
|
{
|
|
FEditorWidgetsStyle::Initialize();
|
|
|
|
ObjectNameEditSinkRegistry = MakeShared<UE::EditorWidgets::FObjectNameEditSinkRegistry>();
|
|
}
|
|
|
|
void FEditorWidgetsModule::ShutdownModule()
|
|
{
|
|
ObjectNameEditSinkRegistry.Reset();
|
|
|
|
FEditorWidgetsStyle::Shutdown();
|
|
}
|
|
|
|
TSharedRef<IObjectNameEditableTextBox> FEditorWidgetsModule::CreateObjectNameEditableTextBox(const TArray<TWeakObjectPtr<UObject>>& Objects)
|
|
{
|
|
TSharedRef<SObjectNameEditableTextBox> Widget = SNew(SObjectNameEditableTextBox).Objects(Objects).Registry(ObjectNameEditSinkRegistry);
|
|
return Widget;
|
|
}
|
|
|
|
TSharedRef<SWidget> FEditorWidgetsModule::CreateAssetDiscoveryIndicator(EAssetDiscoveryIndicatorScaleMode::Type ScaleMode, FMargin Padding, bool bFadeIn)
|
|
{
|
|
return SNew(SAssetDiscoveryIndicator)
|
|
.ScaleMode(ScaleMode)
|
|
.Padding(Padding)
|
|
.FadeIn(bFadeIn);
|
|
}
|
|
|
|
TSharedRef<ITransportControl> FEditorWidgetsModule::CreateTransportControl(const FTransportControlArgs& Args)
|
|
{
|
|
return SNew(STransportControl)
|
|
.TransportArgs(Args);
|
|
}
|
|
|
|
TSharedRef<UE::EditorWidgets::FObjectNameEditSinkRegistry> FEditorWidgetsModule::GetObjectNameEditSinkRegistry() const
|
|
{
|
|
return ObjectNameEditSinkRegistry.ToSharedRef();
|
|
} |