aboutsummaryrefslogtreecommitdiff
path: root/src/ui/ui_manager.cpp
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2019-04-04 23:08:22 +0800
committercrupest <crupest@outlook.com>2019-04-04 23:08:22 +0800
commit6268f3ca09afef812cf288f323cacff22fbfcffc (patch)
tree86e89d3b4212ae069075f799a5278c120e258e73 /src/ui/ui_manager.cpp
parentdbda5a8e4f0d59ad95be8fc3ee7b21e9122cc474 (diff)
downloadcru-6268f3ca09afef812cf288f323cacff22fbfcffc.tar.gz
cru-6268f3ca09afef812cf288f323cacff22fbfcffc.tar.bz2
cru-6268f3ca09afef812cf288f323cacff22fbfcffc.zip
Finish refactor!!!
Diffstat (limited to 'src/ui/ui_manager.cpp')
-rw-r--r--src/ui/ui_manager.cpp15
1 files changed, 8 insertions, 7 deletions
diff --git a/src/ui/ui_manager.cpp b/src/ui/ui_manager.cpp
index 9c3c00d2..b1132ea8 100644
--- a/src/ui/ui_manager.cpp
+++ b/src/ui/ui_manager.cpp
@@ -1,5 +1,7 @@
#include "cru/ui/ui_manager.hpp"
+#include "cru/platform/brush.hpp"
+#include "cru/platform/font.hpp"
#include "cru/platform/graph_factory.hpp"
#include "cru/platform/ui_applicaition.hpp"
@@ -8,13 +10,12 @@ PredefineResources::PredefineResources() {
const auto graph_factory =
platform::UiApplication::GetInstance()->GetGraphFactory();
- button_normal_border_brush.reset(
- graph_factory->CreateSolidColorBrush(colors::black));
-
- text_block_selection_brush.reset(
- graph_factory->CreateSolidColorBrush(colors::skyblue));
- text_block_text_brush.reset(
- graph_factory->CreateSolidColorBrush(colors::black));
+ button_normal_border_brush.reset(static_cast<platform::Brush*>(
+ graph_factory->CreateSolidColorBrush(colors::black)));
+ text_block_selection_brush.reset(static_cast<platform::Brush*>(
+ graph_factory->CreateSolidColorBrush(colors::skyblue)));
+ text_block_text_brush.reset(static_cast<platform::Brush*>(
+ graph_factory->CreateSolidColorBrush(colors::black)));
text_block_font.reset(graph_factory->CreateFontDescriptor(L"等线", 24.0f));
}