mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-10 10:41:50 +00:00
Add source code tooltip to function selection list.
This commit is contained in:
parent
163e7fd490
commit
2031c92f7a
@ -1287,6 +1287,18 @@ void SourceView::RenderSymbolView( Worker& worker, View& view )
|
|||||||
ImGui::Spacing();
|
ImGui::Spacing();
|
||||||
ImGui::SameLine();
|
ImGui::SameLine();
|
||||||
ImGui::TextDisabled( "%s:%i", file, line );
|
ImGui::TextDisabled( "%s:%i", file, line );
|
||||||
|
if( ImGui::IsItemHovered() && SourceFileValid( file, worker.GetCaptureTime(), view, worker ) )
|
||||||
|
{
|
||||||
|
m_sourceTooltip.Parse( file, worker, view );
|
||||||
|
if( !m_sourceTooltip.empty() )
|
||||||
|
{
|
||||||
|
ImGui::BeginTooltip();
|
||||||
|
SetFont();
|
||||||
|
PrintSourceFragment( m_sourceTooltip, line, 4, 7 );
|
||||||
|
UnsetFont();
|
||||||
|
ImGui::EndTooltip();
|
||||||
|
}
|
||||||
|
}
|
||||||
ImGui::NextColumn();
|
ImGui::NextColumn();
|
||||||
ImGui::TextDisabled( "0x%" PRIx64, v.first );
|
ImGui::TextDisabled( "0x%" PRIx64, v.first );
|
||||||
ImGui::NextColumn();
|
ImGui::NextColumn();
|
||||||
|
Loading…
Reference in New Issue
Block a user