mirror of
https://github.com/wolfpld/tracy.git
synced 2024-11-22 14:44:34 +00:00
Worker must be mutable.
This is to allow use of various accessors that cache results, etc.
This commit is contained in:
parent
b481bb367c
commit
119152aac1
@ -5,7 +5,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
TimelineController::TimelineController( View& view, const Worker& worker )
|
||||
TimelineController::TimelineController( View& view, Worker& worker )
|
||||
: m_height( 0 )
|
||||
, m_offset( 0 )
|
||||
, m_scroll( 0 )
|
||||
|
@ -23,7 +23,7 @@ class TimelineController
|
||||
};
|
||||
|
||||
public:
|
||||
TimelineController( View& view, const Worker& worker );
|
||||
TimelineController( View& view, Worker& worker );
|
||||
|
||||
void FirstFrameExpired();
|
||||
void Begin();
|
||||
@ -73,7 +73,7 @@ private:
|
||||
bool m_firstFrame;
|
||||
|
||||
View& m_view;
|
||||
const Worker& m_worker;
|
||||
Worker& m_worker;
|
||||
};
|
||||
|
||||
}
|
||||
|
@ -8,7 +8,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
TimelineItem::TimelineItem( View& view, const Worker& worker )
|
||||
TimelineItem::TimelineItem( View& view, Worker& worker )
|
||||
: m_visible( true )
|
||||
, m_showFull( true )
|
||||
, m_height( 0 )
|
||||
|
@ -14,7 +14,7 @@ class Worker;
|
||||
class TimelineItem
|
||||
{
|
||||
public:
|
||||
TimelineItem( View& view, const Worker& worker );
|
||||
TimelineItem( View& view, Worker& worker );
|
||||
virtual ~TimelineItem() = default;
|
||||
|
||||
void Draw( bool firstFrame, double pxns, int& offset, const ImVec2& wpos, bool hover, float yMin, float yMax );
|
||||
@ -47,7 +47,7 @@ private:
|
||||
|
||||
protected:
|
||||
View& m_view;
|
||||
const Worker& m_worker;
|
||||
Worker& m_worker;
|
||||
};
|
||||
|
||||
}
|
||||
|
@ -8,7 +8,7 @@
|
||||
namespace tracy
|
||||
{
|
||||
|
||||
TimelineItemPlot::TimelineItemPlot( View& view, const Worker& worker, PlotData* plot )
|
||||
TimelineItemPlot::TimelineItemPlot( View& view, Worker& worker, PlotData* plot )
|
||||
: TimelineItem( view, worker )
|
||||
, m_plot( plot )
|
||||
{
|
||||
|
@ -10,7 +10,7 @@ namespace tracy
|
||||
class TimelineItemPlot final : public TimelineItem
|
||||
{
|
||||
public:
|
||||
TimelineItemPlot( View& view, const Worker& worker, PlotData* plot );
|
||||
TimelineItemPlot( View& view, Worker& worker, PlotData* plot );
|
||||
|
||||
void DrawContents( double pxns, int& offset, const ImVec2& wpos, bool hover, float yMin, float yMax ) override;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user