LiveCoding: Explicitly batch all EnableModules() commands, to prevent user command thread preempting the editor thread before it's finished adding everything. Prevents "Live coding ready" messages being spammed in the console window.

#rb none
#jira UE-71270

#ROBOMERGE-OWNER: lina.halper
#ROBOMERGE-AUTHOR: ben.marsh
#ROBOMERGE-SOURCE: CL 5361279 in //UE4/Release-4.22/... via CL 5368485
#ROBOMERGE-BOT: ANIM (Main -> Dev-Anim)

[CL 5381900 by ben marsh in Dev-Anim branch]
This commit is contained in:
ben marsh
2019-03-13 10:02:59 -04:00
parent b5e48810ff
commit 0f45be443f
2 changed files with 18 additions and 0 deletions

View File

@@ -240,6 +240,9 @@ void FLiveCodingModule::UpdateModules()
TArray<FModuleStatus> ModuleStatuses;
FModuleManager::Get().QueryModules(ModuleStatuses);
extern void BeginCommandBatch();
BeginCommandBatch();
for (const FModuleStatus& ModuleStatus : ModuleStatuses)
{
if (ModuleStatus.bIsLoaded)
@@ -248,6 +251,9 @@ void FLiveCodingModule::UpdateModules()
ConfigureModule(FName(*ModuleStatus.Name), ModuleStatus.bIsGameModule, FullFilePath);
}
}
extern void EndCommandBatch();
EndCommandBatch();
#endif
}