mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-23 06:44:35 +00:00
Switching between source files from asm view.
This commit is contained in:
parent
3f01d3bcb1
commit
0551cd8e44
@ -864,13 +864,24 @@ void SourceView::RenderAsmLine( const AsmLine& line, uint32_t ipcnt, uint32_t ip
|
|||||||
ImGui::Text( "%s:%i", fileName, srcline );
|
ImGui::Text( "%s:%i", fileName, srcline );
|
||||||
ImGui::EndTooltip();
|
ImGui::EndTooltip();
|
||||||
if( m_font ) ImGui::PushFont( m_font );
|
if( m_font ) ImGui::PushFont( m_font );
|
||||||
if( !m_lines.empty() && m_file == fileName && ImGui::IsItemClicked() )
|
if( ImGui::IsItemClicked() )
|
||||||
|
{
|
||||||
|
if( m_file == fileName )
|
||||||
{
|
{
|
||||||
m_currentAddr = line.addr;
|
m_currentAddr = line.addr;
|
||||||
m_targetLine = srcline;
|
m_targetLine = srcline;
|
||||||
m_selectedLine = srcline;
|
m_selectedLine = srcline;
|
||||||
m_displayMode = DisplayMixed;
|
m_displayMode = DisplayMixed;
|
||||||
}
|
}
|
||||||
|
else if( SourceFileValid( fileName, worker.GetCaptureTime() ) )
|
||||||
|
{
|
||||||
|
ParseSource( fileName, &worker );
|
||||||
|
m_currentAddr = line.addr;
|
||||||
|
m_targetLine = srcline;
|
||||||
|
m_selectedLine = srcline;
|
||||||
|
m_displayMode = DisplayMixed;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
ImGui::SameLine( 0, 0 );
|
ImGui::SameLine( 0, 0 );
|
||||||
ImGui::ItemSize( ImVec2( stw * ( 32 - bufsz ), ty ), 0 );
|
ImGui::ItemSize( ImVec2( stw * ( 32 - bufsz ), ty ), 0 );
|
||||||
|
Loading…
Reference in New Issue
Block a user