From 3b34ebf54401c06cef92f12ddd8f15dbbb64e151 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Mon, 19 Mar 2018 02:25:24 +0100 Subject: [PATCH] Unify GPU info window child selection with the rest of lists. --- server/TracyView.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index 5a822b6b..ef9e92fc 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -2571,14 +2571,14 @@ void View::DrawGpuInfoWindow() { auto& cev = *ev.child[cti[i]]; const auto& csl = m_worker.GetSourceLocation( cev.srcloc ); - ImGui::Text( "%s", m_worker.GetString( csl.name ) ); + bool b = false; + if( ImGui::Selectable( m_worker.GetString( csl.name ), &b, ImGuiSelectableFlags_SpanAllColumns ) ) + { + m_gpuInfoWindow = &cev; + } if( ImGui::IsItemHovered() ) { m_gpuHighlight = &cev; - if( ImGui::IsMouseClicked( 0 ) ) - { - m_gpuInfoWindow = &cev; - } if( ImGui::IsMouseClicked( 2 ) ) { ZoomToZone( cev );