mirror of
https://github.com/Ed94/Cog.git
synced 2026-06-13 00:01:37 -07:00
Fix assert when disconnecting
This commit is contained in:
@@ -633,7 +633,16 @@ void ClientInfo::ContextRestore()
|
||||
if (IsContextOverriden() && ImGui::GetCurrentContext() == mpContext)
|
||||
{
|
||||
#ifdef IMGUI_HAS_VIEWPORT
|
||||
ImGui::UpdatePlatformWindows(); // Prevents issue with mismatched frame tracking, when restoring enabled viewport feature
|
||||
|
||||
//*************************************************************************************************
|
||||
// COG: Disabling the call ImGui::UpdatePlatformWindows() otherwise it gets called twice when
|
||||
// disconnecting causing this assert in ImGui::UpdatePlatformWindows():
|
||||
//
|
||||
// IM_ASSERT(g.FrameCountPlatformEnded < g.FrameCount);
|
||||
//*************************************************************************************************
|
||||
|
||||
//ImGui::UpdatePlatformWindows(); // Prevents issue with mismatched frame tracking, when restoring enabled viewport feature
|
||||
|
||||
#endif
|
||||
if( mFontCreationFunction && ImGui::GetIO().Fonts && ImGui::GetIO().Fonts->Fonts.size() > 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user