From 5a7304171dc91df67539e4ea24963af90557ebaf Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sun, 27 May 2018 20:22:58 +0200 Subject: [PATCH] Fix allocation times displayed in plot tooltip. --- server/TracyView.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index d5f33c08..6fcc798e 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -2640,7 +2640,7 @@ void View::DrawPlotPoint( const ImVec2& wpos, float x, float y, int offset, uint { ImGui::Separator(); ImGui::Text( "Address: 0x%" PRIx64, ev->ptr ); - ImGui::Text( "Appeared at %s", TimeToString( m_worker.GetLastTime() - ev->timeAlloc ) ); + ImGui::Text( "Appeared at %s", TimeToString( ev->timeAlloc - m_worker.GetFrameBegin( 0 ) ) ); if( change > 0 ) { ImGui::SameLine(); @@ -2652,7 +2652,7 @@ void View::DrawPlotPoint( const ImVec2& wpos, float x, float y, int offset, uint } else { - ImGui::Text( "Freed at %s", TimeToString( m_worker.GetLastTime() - ev->timeFree ) ); + ImGui::Text( "Freed at %s", TimeToString( ev->timeFree - m_worker.GetFrameBegin( 0 ) ) ); if( change < 0 ) { ImGui::SameLine();