mirror of
https://github.com/wolfpld/tracy.git
synced 2026-10-16 13:55:27 +00:00
Display ellipsis in single-line callstack printout, when frames remain.
This commit is contained in:
@@ -629,8 +629,11 @@ void View::DrawCallstackCalls( uint32_t callstack, uint16_t limit ) const
|
||||
{
|
||||
const auto& csdata = m_worker.GetCallstack( callstack );
|
||||
bool first = true;
|
||||
for( auto& v : csdata )
|
||||
|
||||
int i;
|
||||
for( i = 0; i < csdata.size(); i++ )
|
||||
{
|
||||
const auto& v = csdata[i];
|
||||
const auto frameData = m_worker.GetCallstackFrame( v );
|
||||
if( !frameData ) break;
|
||||
const auto& frame = frameData->data[frameData->size - 1];
|
||||
@@ -662,6 +665,29 @@ void View::DrawCallstackCalls( uint32_t callstack, uint16_t limit ) const
|
||||
}
|
||||
if( --limit == 0 ) break;
|
||||
}
|
||||
if( limit == 0 )
|
||||
{
|
||||
bool framesLeft = false;
|
||||
while( ++i < csdata.size() )
|
||||
{
|
||||
const auto& v = csdata[i];
|
||||
const auto frameData = m_worker.GetCallstackFrame( v );
|
||||
if( !frameData ) break;
|
||||
const auto& frame = frameData->data[frameData->size - 1];
|
||||
auto filename = m_worker.GetString( frame.file );
|
||||
auto image = frameData->imageName.Active() ? m_worker.GetString( frameData->imageName ) : nullptr;
|
||||
if( IsFrameExternal( filename, image ) ) continue;
|
||||
framesLeft = true;
|
||||
break;
|
||||
}
|
||||
if( framesLeft )
|
||||
{
|
||||
ImGui::SameLine();
|
||||
TextDisabledUnformatted( ICON_FA_LEFT_LONG );
|
||||
ImGui::SameLine();
|
||||
TextDisabledUnformatted( ICON_FA_ELLIPSIS );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void View::CallstackTooltip( uint32_t idx )
|
||||
|
||||
Reference in New Issue
Block a user