mirror of
https://github.com/wolfpld/tracy
synced 2025-04-29 12:23:53 +00:00
Add context menu with hide option to threads on timeline.
This commit is contained in:
parent
5ef7e42223
commit
fa8a071334
@ -603,6 +603,7 @@ void View::DrawTimeline()
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
bool showFull = vis.showFull;
|
bool showFull = vis.showFull;
|
||||||
|
ImGui::PushID( &vis );
|
||||||
|
|
||||||
const auto yPos = AdjustThreadPosition( vis, wpos.y, offset );
|
const auto yPos = AdjustThreadPosition( vis, wpos.y, offset );
|
||||||
const auto oldOffset = offset;
|
const auto oldOffset = offset;
|
||||||
@ -962,12 +963,27 @@ void View::DrawTimeline()
|
|||||||
{
|
{
|
||||||
ZoomToRange( first, last );
|
ZoomToRange( first, last );
|
||||||
}
|
}
|
||||||
|
if( IsMouseClicked( 1 ) )
|
||||||
|
{
|
||||||
|
ImGui::OpenPopup( "menuPopup" );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( ImGui::BeginPopup( "menuPopup" ) )
|
||||||
|
{
|
||||||
|
if( ImGui::MenuItem( ICON_FA_EYE_SLASH " Hide" ) )
|
||||||
|
{
|
||||||
|
vis.visible = false;
|
||||||
|
ImGui::CloseCurrentPopup();
|
||||||
|
}
|
||||||
|
ImGui::EndPopup();
|
||||||
|
}
|
||||||
|
|
||||||
AdjustThreadHeight( Vis( v ), oldOffset, offset );
|
AdjustThreadHeight( Vis( v ), oldOffset, offset );
|
||||||
ImGui::PopClipRect();
|
ImGui::PopClipRect();
|
||||||
|
ImGui::PopID();
|
||||||
}
|
}
|
||||||
m_lockHighlight = nextLockHighlight;
|
m_lockHighlight = nextLockHighlight;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user