aboutsummaryrefslogtreecommitdiff
path: root/CruUI/graph/graph.cpp
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2018-09-16 23:48:54 +0800
committercrupest <crupest@outlook.com>2018-09-16 23:48:54 +0800
commit94c066a34900845297c41c134a9a910124a5833d (patch)
treefe717d4d80137c005ae3f2c1675ab3ba7d990b23 /CruUI/graph/graph.cpp
parent683419f2856d348436ca64cfd4b3abbfc73cda89 (diff)
downloadcru-94c066a34900845297c41c134a9a910124a5833d.tar.gz
cru-94c066a34900845297c41c134a9a910124a5833d.tar.bz2
cru-94c066a34900845297c41c134a9a910124a5833d.zip
Develop toggle button.
Diffstat (limited to 'CruUI/graph/graph.cpp')
-rw-r--r--CruUI/graph/graph.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/CruUI/graph/graph.cpp b/CruUI/graph/graph.cpp
index 00d5137d..94c7029e 100644
--- a/CruUI/graph/graph.cpp
+++ b/CruUI/graph/graph.cpp
@@ -213,5 +213,13 @@ namespace cru {
d2d1_factory_->ReloadSystemMetrics()
);
}
+
+ ComPtr<ID2D1SolidColorBrush> CreateSolidBrush(const D2D1_COLOR_F& color)
+ {
+ const auto device_context = graph::GraphManager::GetInstance()->GetD2D1DeviceContext();
+ ComPtr<ID2D1SolidColorBrush> solid_color_brush;
+ device_context->CreateSolidColorBrush(color, &solid_color_brush);
+ return solid_color_brush;
+ }
}
}