animationmgr: avoid redundant ticks

This commit is contained in:
vaxerski
2023-08-05 23:29:33 +02:00
parent b925f1b497
commit a077b7a92e
5 changed files with 52 additions and 9 deletions

View File

@@ -13,6 +13,8 @@ class CAnimationManager {
CAnimationManager();
void tick();
bool shouldTickForNext();
void scheduleTick();
void addBezierWithName(std::string, const Vector2D&, const Vector2D&);
void removeAllBeziers();
@@ -42,6 +44,8 @@ class CAnimationManager {
std::unordered_map<std::string, CBezierCurve> m_mBezierCurves;
bool m_bTickScheduled = false;
// Anim stuff
void animationPopin(CWindow*, bool close = false, float minPerc = 0.f);
void animationSlide(CWindow*, std::string force = "", bool close = false);