mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-10 10:41:50 +00:00
Make zone info child list "selectable".
This commit is contained in:
parent
a7e7f59f96
commit
f44e9bbd7b
@ -2458,21 +2458,15 @@ void View::DrawZoneInfoWindow()
|
||||
{
|
||||
auto& cev = *ev.child[cti[i]];
|
||||
const auto& csl = m_worker.GetSourceLocation( cev.srcloc );
|
||||
if( csl.name.active )
|
||||
const auto txt = csl.name.active ? m_worker.GetString( csl.name ) : m_worker.GetString( csl.function );
|
||||
bool b = false;
|
||||
if( ImGui::Selectable( txt, &b, ImGuiSelectableFlags_SpanAllColumns ) )
|
||||
{
|
||||
ImGui::Text( "%s", m_worker.GetString( csl.name ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
ImGui::Text( "%s", m_worker.GetString( csl.function ) );
|
||||
m_zoneInfoWindow = &cev;
|
||||
}
|
||||
if( ImGui::IsItemHovered() )
|
||||
{
|
||||
m_zoneHighlight = &cev;
|
||||
if( ImGui::IsMouseClicked( 0 ) )
|
||||
{
|
||||
m_zoneInfoWindow = &cev;
|
||||
}
|
||||
if( ImGui::IsMouseClicked( 2 ) )
|
||||
{
|
||||
ZoomToZone( cev );
|
||||
|
Loading…
Reference in New Issue
Block a user