1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Add zone color boxes to statistics menu.

This commit is contained in:
Bartosz Taudul 2019-11-02 23:00:42 +01:00
parent 04cb7732b8
commit 3a304ad054

View File

@ -10197,9 +10197,10 @@ void View::DrawStatistics()
for( auto& v : srcloc )
{
ImGui::PushID( v->first );
auto& srcloc = m_worker.GetSourceLocation( v->first );
auto name = m_worker.GetString( srcloc.name.active ? srcloc.name : srcloc.function );
SmallColorBox( GetSrcLocColor( srcloc, 0 ) );
ImGui::SameLine();
if( ImGui::Selectable( name, m_findZone.show && !m_findZone.match.empty() && m_findZone.match[m_findZone.selMatch] == v->first, ImGuiSelectableFlags_SpanAllColumns ) )
{
m_findZone.ShowZone( v->first, name );