Don't issue warning if only disconnect is in send queue.

This commit is contained in:
Bartosz Taudul 2021-04-01 20:16:47 +02:00
parent 9b7f759347
commit 592644ae43
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3

View File

@ -1133,7 +1133,8 @@ bool View::DrawImpl()
if( m_reactToLostConnection && !m_worker.IsConnected() ) if( m_reactToLostConnection && !m_worker.IsConnected() )
{ {
m_reactToLostConnection = false; m_reactToLostConnection = false;
if( m_worker.GetSendInFlight() > 0 ) const auto inFlight = m_worker.GetSendInFlight();
if( inFlight > 1 || ( inFlight == 1 && !m_worker.WasDisconnectIssued() ) )
{ {
ImGui::OpenPopup( "Connection lost!" ); ImGui::OpenPopup( "Connection lost!" );
} }