mirror of
https://github.com/wolfpld/tracy
synced 2025-04-28 20:23:51 +00:00
Add appropriate tooltips for image names.
This commit is contained in:
parent
408939862b
commit
c38764db3c
@ -528,10 +528,15 @@ void View::DrawSamplesStatistics( Vector<SymList>& data, int64_t timeRange, Accu
|
||||
while( end > imageName && *end != '/' && *end != '\\' ) end--;
|
||||
if( *end == '/' || *end == '\\' ) end++;
|
||||
TextDisabledUnformatted( end );
|
||||
TooltipIfHovered( imageName );
|
||||
}
|
||||
else
|
||||
{
|
||||
const char* end = imageName + strlen( imageName );
|
||||
const auto cw = ImGui::GetContentRegionAvail().x;
|
||||
const auto tw = ImGui::CalcTextSize( imageName, end ).x;
|
||||
TextDisabledUnformatted( imageName );
|
||||
if( tw > cw ) TooltipIfHovered( imageName );
|
||||
}
|
||||
ImGui::TableNextColumn();
|
||||
const auto baseCnt = cnt;
|
||||
|
Loading…
x
Reference in New Issue
Block a user