You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
#ue4 CIS fix: Check for FSlateApplication validity.
[CL 2048812 by Thomas Sarkanen in Main branch]
This commit is contained in:
committed by
UnrealBot
parent
480ea3af20
commit
4cf4d2af19
@@ -78,8 +78,11 @@ void FSourceCodeAccessModule::SetAccessor(const FName& InName)
|
||||
if(InName == Accessor.GetFName())
|
||||
{
|
||||
CurrentSourceCodeAccessor = static_cast<ISourceCodeAccessor*>(Feature);
|
||||
FSlateApplication::Get().SetWidgetReflectorSourceAccessDelegate( FAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::OpenFileAtLine ) );
|
||||
FSlateApplication::Get().SetWidgetReflectorQuerySourceAccessDelegate( FQueryAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::CanAccessSourceCode ) );
|
||||
if(FSlateApplication::IsInitialized())
|
||||
{
|
||||
FSlateApplication::Get().SetWidgetReflectorSourceAccessDelegate( FAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::OpenFileAtLine ) );
|
||||
FSlateApplication::Get().SetWidgetReflectorQuerySourceAccessDelegate( FQueryAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::CanAccessSourceCode ) );
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -123,8 +126,11 @@ void FSourceCodeAccessModule::HandleModularFeatureRegistered(const FName& Type)
|
||||
if(PreferredAccessor == Accessor.GetFName().ToString())
|
||||
{
|
||||
CurrentSourceCodeAccessor = static_cast<ISourceCodeAccessor*>(Feature);
|
||||
FSlateApplication::Get().SetWidgetReflectorSourceAccessDelegate( FAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::OpenFileAtLine ) );
|
||||
FSlateApplication::Get().SetWidgetReflectorQuerySourceAccessDelegate( FQueryAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::CanAccessSourceCode ) );
|
||||
if(FSlateApplication::IsInitialized())
|
||||
{
|
||||
FSlateApplication::Get().SetWidgetReflectorSourceAccessDelegate( FAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::OpenFileAtLine ) );
|
||||
FSlateApplication::Get().SetWidgetReflectorQuerySourceAccessDelegate( FQueryAccessSourceCode::CreateRaw( CurrentSourceCodeAccessor, &ISourceCodeAccessor::CanAccessSourceCode ) );
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user