mirror of
https://github.com/wolfpld/tracy
synced 2025-04-29 04:23:51 +00:00
Expose IsFrameExternal as View's method.
This commit is contained in:
parent
1e796064bc
commit
70fc28506f
@ -314,6 +314,7 @@ private:
|
||||
|
||||
void AddAnnotation( int64_t start, int64_t end );
|
||||
|
||||
bool IsFrameExternal( const char* filename, const char* image );
|
||||
uint32_t GetThreadColor( uint64_t thread, int depth );
|
||||
uint32_t GetSrcLocColor( const SourceLocation& srcloc, int depth );
|
||||
uint32_t GetRawSrcLocColor( const SourceLocation& srcloc, int depth );
|
||||
|
@ -10,14 +10,6 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
static bool IsFrameExternal( const char* filename, const char* image )
|
||||
{
|
||||
if( strncmp( filename, "/usr/", 5 ) == 0 || strncmp( filename, "/lib/", 5 ) == 0 || strcmp( filename, "[unknown]" ) == 0 || strcmp( filename, "<kernel>" ) == 0 ) return true;
|
||||
if( strncmp( filename, "C:\\Program Files\\", 17 ) == 0 || strncmp( filename, "d:\\a01\\_work\\", 13 ) == 0 ) return true;
|
||||
if( !image ) return false;
|
||||
return strncmp( image, "/usr/", 5 ) == 0 || strncmp( image, "/lib/", 5 ) == 0 || strncmp( image, "/lib64/", 7 ) == 0 || strcmp( image, "<kernel>" ) == 0;
|
||||
}
|
||||
|
||||
void View::DrawCallstackWindow()
|
||||
{
|
||||
bool show = true;
|
||||
|
@ -8,6 +8,14 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
bool View::IsFrameExternal( const char* filename, const char* image )
|
||||
{
|
||||
if( strncmp( filename, "/usr/", 5 ) == 0 || strncmp( filename, "/lib/", 5 ) == 0 || strcmp( filename, "[unknown]" ) == 0 || strcmp( filename, "<kernel>" ) == 0 ) return true;
|
||||
if( strncmp( filename, "C:\\Program Files\\", 17 ) == 0 || strncmp( filename, "d:\\a01\\_work\\", 13 ) == 0 ) return true;
|
||||
if( !image ) return false;
|
||||
return strncmp( image, "/usr/", 5 ) == 0 || strncmp( image, "/lib/", 5 ) == 0 || strncmp( image, "/lib64/", 7 ) == 0 || strcmp( image, "<kernel>" ) == 0;
|
||||
}
|
||||
|
||||
uint32_t View::GetThreadColor( uint64_t thread, int depth )
|
||||
{
|
||||
return tracy::GetThreadColor( thread, depth, m_vd.dynamicColors != 0 );
|
||||
|
Loading…
x
Reference in New Issue
Block a user