diff options
author | crupest <crupest@outlook.com> | 2018-09-18 01:38:02 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2018-09-18 01:38:02 +0800 |
commit | 4710715102df3806479985679bd8048631ccaab5 (patch) | |
tree | 0f18f3c1d278aace11521a93abad97c97eb4ae54 /CruUI/application.cpp | |
parent | 94c066a34900845297c41c134a9a910124a5833d (diff) | |
download | cru-4710715102df3806479985679bd8048631ccaab5.tar.gz cru-4710715102df3806479985679bd8048631ccaab5.tar.bz2 cru-4710715102df3806479985679bd8048631ccaab5.zip |
I think I can't sleep well after this commit.
Still a lot of bugs!!!
Diffstat (limited to 'CruUI/application.cpp')
-rw-r--r-- | CruUI/application.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/CruUI/application.cpp b/CruUI/application.cpp index 04b18ff0..f1d57153 100644 --- a/CruUI/application.cpp +++ b/CruUI/application.cpp @@ -5,6 +5,7 @@ #include "timer.h" #include "ui/window.h" #include "graph/graph.h" +#include "ui/animations/animation.h" namespace cru { constexpr auto god_window_class_name = L"GodWindowClass"; @@ -63,9 +64,9 @@ namespace cru { case WM_TIMER: { const auto action = application_->GetTimerManager()->GetAction(static_cast<UINT_PTR>(w_param)); - if (action.has_value()) + if (action) { - action.value()(); + (*action)(); return 0; } break; @@ -95,6 +96,7 @@ namespace cru { window_manager_ = std::make_unique<ui::WindowManager>(); graph_manager_ = std::make_unique<graph::GraphManager>(); timer_manager_ = std::make_unique<TimerManager>(); + animation_manager_ = std::make_unique<ui::animations::AnimationManager>(); god_window_ = std::make_unique<GodWindow>(this); } |