From 3ee928a7d1d4089580fd7896845ca87fb6ed9b0a Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Sat, 3 Sep 2022 22:08:08 +0200 Subject: [PATCH] Fix mass visibility changing. --- server/TracyTimelineItem.hpp | 1 + server/TracyView_Options.cpp | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/server/TracyTimelineItem.hpp b/server/TracyTimelineItem.hpp index 5fb6270e..ae8381fa 100644 --- a/server/TracyTimelineItem.hpp +++ b/server/TracyTimelineItem.hpp @@ -23,6 +23,7 @@ public: virtual bool IsEmpty() const { return false; } void VisibilityCheckbox(); + void SetVisible( bool visible ) { m_visible = visible; } protected: virtual uint32_t HeaderColor() const = 0; diff --git a/server/TracyView_Options.cpp b/server/TracyView_Options.cpp index 52bae161..22c5d665 100644 --- a/server/TracyView_Options.cpp +++ b/server/TracyView_Options.cpp @@ -549,7 +549,7 @@ void View::DrawOptions() { for( const auto& p : m_worker.GetPlots() ) { - m_tc.Vis( p ).visible = true; + m_tc.GetItem( p ).SetVisible( true ); } } ImGui::SameLine(); @@ -557,7 +557,7 @@ void View::DrawOptions() { for( const auto& p : m_worker.GetPlots() ) { - m_tc.Vis( p ).visible = false; + m_tc.GetItem( p ).SetVisible( false ); } }