Only run update and check_timer functions on components that need it
This commit is contained in:
parent
f82e626686
commit
1c1f23d68d
2 changed files with 27 additions and 4 deletions
|
|
@ -55,9 +55,15 @@ class DrawingProgram {
|
|||
|
||||
CollabListType components;
|
||||
|
||||
std::unordered_set<std::shared_ptr<DrawComponent>> updateableComponents;
|
||||
std::unordered_set<std::shared_ptr<DrawComponent>> delayedUpdateTransformComponents;
|
||||
|
||||
Vector4f* get_foreground_color_ptr();
|
||||
private:
|
||||
|
||||
void check_delayed_update_transform_timers();
|
||||
void check_updateable_components();
|
||||
|
||||
std::atomic<bool> addFileInNextFrame = false;
|
||||
std::pair<std::string, Vector2f> addFileInfo;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue