From 5f7d3268e3d2ea84a1afc97c209b703bf4092c76 Mon Sep 17 00:00:00 2001 From: crupest Date: Thu, 20 Sep 2018 22:50:37 +0800 Subject: Improve linear layout. --- CruUI/ui/window.cpp | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'CruUI/ui/window.cpp') diff --git a/CruUI/ui/window.cpp b/CruUI/ui/window.cpp index 926fd77a..21528d9d 100644 --- a/CruUI/ui/window.cpp +++ b/CruUI/ui/window.cpp @@ -77,6 +77,14 @@ namespace cru return find_result->second; } + Vector WindowManager::GetAllWindows() const + { + Vector windows; + for (auto [key, value] : window_map_) + windows.push_back(value); + return std::move(windows); + } + inline Point PiToDip(const POINT& pi_point) { return Point( @@ -401,6 +409,17 @@ namespace cru } } +#ifdef CRU_DEBUG_DRAW_CONTROL_BORDER + void Window::SetDebugDrawControlBorder(const bool value) + { + if (debug_draw_control_border_ != value) + { + debug_draw_control_border_ = value; + Repaint(); + } + } +#endif + RECT Window::GetClientRectPixel() { RECT rect{ }; GetClientRect(hwnd_, &rect); -- cgit v1.2.3