Removed from FImGuiModuleManager custom check for a game thread as both reasons to have it are not relevant any more.

Current implementation of the IsInGameThread() doesn't make exceptions for a loading thread and lazy initialization of the Unreal resources ensures that plugin doesn't do any work before the game starts.
This commit is contained in:
Sebastian 2019-06-15 13:37:11 +01:00
parent 505eb166d5
commit 2d728f1f26
2 changed files with 1 additions and 10 deletions

View File

@ -147,16 +147,9 @@ void FImGuiModuleManager::ReleaseTickInitializer()
}
}
bool FImGuiModuleManager::IsInUpdateThread()
{
// We can get ticks from the Game thread and Slate loading thread. In both cases IsInGameThread() is true, so we
// need to make additional test to filter out loading thread.
return IsInGameThread() && !IsInSlateThread();
}
void FImGuiModuleManager::Tick(float DeltaSeconds)
{
if (IsInUpdateThread())
if (IsInGameThread())
{
// Update context manager to advance all ImGui contexts to the next frame.
ContextManager.Tick(DeltaSeconds);

View File

@ -54,8 +54,6 @@ private:
void CreateTickInitializer();
void ReleaseTickInitializer();
bool IsInUpdateThread();
void Tick(float DeltaSeconds);
void OnViewportCreated();