From 9155b01ddfad9310b21cd2832c092b8e90e6586e Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sat, 4 Mar 2023 00:25:30 +0100 Subject: [PATCH] Use on demand flag to determine if need to show missed frames. --- server/TracyView_FrameOverview.cpp | 3 +-- server/TracyView_Utility.cpp | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/server/TracyView_FrameOverview.cpp b/server/TracyView_FrameOverview.cpp index 6955c2d6..a0ae69a9 100644 --- a/server/TracyView_FrameOverview.cpp +++ b/server/TracyView_FrameOverview.cpp @@ -145,14 +145,13 @@ void View::DrawFrames() m_frameHover = sel; if( m_frames->name == 0 ) { - const auto offset = m_worker.GetFrameOffset(); if( sel == 0 ) { ImGui::TextUnformatted( "Tracy initialization" ); ImGui::Separator(); TextFocused( "Time:", TimeToString( m_worker.GetFrameTime( *m_frames, sel ) ) ); } - else if( offset == 0 ) + else if( !m_worker.IsOnDemand() ) { TextDisabledUnformatted( "Frame:" ); ImGui::SameLine(); diff --git a/server/TracyView_Utility.cpp b/server/TracyView_Utility.cpp index 1cb71a02..3ca8341f 100644 --- a/server/TracyView_Utility.cpp +++ b/server/TracyView_Utility.cpp @@ -778,7 +778,7 @@ const char* View::GetFrameText( const FrameData& fd, int i, uint64_t ftime, uint { sprintf( buf, "Tracy init (%s)", TimeToString( ftime ) ); } - else if( offset == 0 ) + else if( !m_worker.IsOnDemand() ) { sprintf( buf, "Frame %s (%s)", RealToString( fnum ), TimeToString( ftime ) ); }