Fix going to a phantom line when there's no source file available.

This commit is contained in:
Bartosz Taudul 2024-10-04 18:01:51 +02:00
parent a8c6c5f50e
commit 9ab2f35c08
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3

View File

@ -3950,14 +3950,15 @@ void SourceView::RenderAsmLine( AsmLine& line, const AddrStat& ipcnt, const Addr
SetFont();
if( ImGui::IsItemClicked( 0 ) )
{
m_targetLine = srcline;
if( m_source.filename() == fileName )
{
m_targetLine = srcline;
SelectLine( srcline, &worker, false );
m_displayMode = DisplayMixed;
}
else if( SourceFileValid( fileName, worker.GetCaptureTime(), view, worker ) )
{
m_targetLine = srcline;
ParseSource( fileName, worker, view );
SelectLine( srcline, &worker, false );
SelectViewMode();