mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-22 14:44:34 +00:00
Change magic value enums to constexprs.
This commit is contained in:
parent
77e39700b1
commit
d12fa11762
@ -219,8 +219,8 @@ static void PrintSourceFragment( const SourceContents& src, uint32_t srcline, in
|
||||
}
|
||||
|
||||
|
||||
enum { JumpSeparationBase = 6 };
|
||||
enum { JumpArrowBase = 9 };
|
||||
constexpr float JumpSeparationBase = 6;
|
||||
constexpr float JumpArrowBase = 9;
|
||||
|
||||
SourceView::SourceView()
|
||||
: m_font( nullptr )
|
||||
|
@ -8,7 +8,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinCtxSize = 4 };
|
||||
constexpr float MinCtxSize = 4;
|
||||
|
||||
const char* View::DecodeContextSwitchReasonCode( uint8_t reason )
|
||||
{
|
||||
|
@ -9,7 +9,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinVisSize = 3 };
|
||||
constexpr float MinVisSize = 3;
|
||||
|
||||
int View::DrawCpuData( int offset, double pxns, const ImVec2& wpos, bool hover, float yMin, float yMax )
|
||||
{
|
||||
|
@ -10,8 +10,8 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinVisSize = 3 };
|
||||
enum { MinFrameSize = 5 };
|
||||
constexpr float MinVisSize = 3;
|
||||
constexpr float MinFrameSize = 5;
|
||||
|
||||
static tracy_force_inline uint32_t GetColorMuted( uint32_t color, bool active )
|
||||
{
|
||||
|
@ -10,7 +10,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinVisSize = 3 };
|
||||
constexpr float MinVisSize = 3;
|
||||
|
||||
static tracy_force_inline uint64_t GetThreadBit( uint8_t thread )
|
||||
{
|
||||
|
@ -9,7 +9,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinVisSize = 3 };
|
||||
constexpr float MinVisSize = 3;
|
||||
|
||||
extern double s_time;
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
enum { MinVisSize = 3 };
|
||||
constexpr float MinVisSize = 3;
|
||||
|
||||
static tracy_force_inline uint32_t MixGhostColor( uint32_t c0, uint32_t c1 )
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user