diff options
author | 杨宇千 <crupest@outlook.com> | 2018-11-10 22:39:26 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-11-10 22:39:26 +0800 |
commit | 8b04c0dd788be75c2dd7d8f58aebc7d6bf6752df (patch) | |
tree | 2d00b4f6a7af93a13d271d78e6ef682c335c91c7 /src/ui/control.cpp | |
parent | 7c2fb4578b6997b5ab0d98121cda253f734139c1 (diff) | |
parent | b2eced8d9719eb00796c2674fc2c23ab0c9bbdbf (diff) | |
download | cru-8b04c0dd788be75c2dd7d8f58aebc7d6bf6752df.tar.gz cru-8b04c0dd788be75c2dd7d8f58aebc7d6bf6752df.tar.bz2 cru-8b04c0dd788be75c2dd7d8f58aebc7d6bf6752df.zip |
Merge pull request #11 from crupest/listitem
Add ListItem.
Diffstat (limited to 'src/ui/control.cpp')
-rw-r--r-- | src/ui/control.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/ui/control.cpp b/src/ui/control.cpp index 5d15e287..2d09a382 100644 --- a/src/ui/control.cpp +++ b/src/ui/control.cpp @@ -7,6 +7,7 @@ #include "graph/graph.hpp" #include "exception.hpp" #include "cru_debug.hpp" +#include "convert_util.hpp" #ifdef CRU_DEBUG_LAYOUT #include "ui_manager.hpp" @@ -237,7 +238,7 @@ namespace cru::ui void Control::InvalidateLayout() { if (const auto window = GetWindow()) - LayoutManager::GetInstance()->InvalidateWindowLayout(window); + window->WindowInvalidateLayout(); } void Control::Measure(const Size& available_size) @@ -376,12 +377,6 @@ namespace cru::ui window_ = nullptr; } - - inline D2D1_RECT_F Convert(const Rect& rect) - { - return D2D1::RectF(rect.left, rect.top, rect.left + rect.width, rect.top + rect.height); - } - void Control::OnDrawCore(ID2D1DeviceContext* device_context) { #ifdef CRU_DEBUG_LAYOUT |