diff --git a/server/TracySourceView.cpp b/server/TracySourceView.cpp index 7992a73c..debe9c03 100644 --- a/server/TracySourceView.cpp +++ b/server/TracySourceView.cpp @@ -856,10 +856,13 @@ void SourceView::RenderSymbolSourceView( uint32_t iptotal, unordered_flat_map ipcount, uint32_t ipmax, const Worker& worker ) { SmallCheckbox( ICON_FA_SEARCH_LOCATION " Relative locations", &m_asmRelative ); - ImGui::SameLine(); - ImGui::Spacing(); - ImGui::SameLine(); - SmallCheckbox( ICON_FA_FILE_IMPORT " Show source locations", &m_asmShowSourceLocation ); + if( !m_sourceFiles.empty() ) + { + ImGui::SameLine(); + ImGui::Spacing(); + ImGui::SameLine(); + SmallCheckbox( ICON_FA_FILE_IMPORT " Show source locations", &m_asmShowSourceLocation ); + } ImGui::SameLine(); ImGui::Spacing(); ImGui::SameLine(); @@ -927,7 +930,7 @@ uint64_t SourceView::RenderSymbolAsmView( uint32_t iptotal, unordered_flat_mapAddLine( wpos + ImVec2( xoff + JumpSeparation * mjl + th2, th2 ), wpos + ImVec2( xoff + JumpSeparation * mjl + th2 + JumpArrow / 2, th2 ), col ); draw->AddLine( wpos + ImVec2( xoff + JumpSeparation * mjl + th2, th2 ), wpos + ImVec2( xoff + JumpSeparation * mjl + th2 + th4, th2 - th4 ), col );