aboutsummaryrefslogtreecommitdiff
path: root/src/ui/render/render_object.hpp
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2019-03-23 00:15:18 +0800
committercrupest <crupest@outlook.com>2019-03-23 00:15:18 +0800
commit39d2c8b3d957e75c3a2a1c738c1628e3eb5c0173 (patch)
tree72fff34573ffc7e788051bd7911032283340588d /src/ui/render/render_object.hpp
parent63a5d619ac81ba3f48e95c890d96fa7d9047bb26 (diff)
downloadcru-39d2c8b3d957e75c3a2a1c738c1628e3eb5c0173.tar.gz
cru-39d2c8b3d957e75c3a2a1c738c1628e3eb5c0173.tar.bz2
cru-39d2c8b3d957e75c3a2a1c738c1628e3eb5c0173.zip
...
Diffstat (limited to 'src/ui/render/render_object.hpp')
-rw-r--r--src/ui/render/render_object.hpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/ui/render/render_object.hpp b/src/ui/render/render_object.hpp
index a9950198..51b0c3ae 100644
--- a/src/ui/render/render_object.hpp
+++ b/src/ui/render/render_object.hpp
@@ -3,11 +3,13 @@
#include <optional>
#include <vector>
-#include "system_headers.hpp"
#include "base.hpp"
#include "ui/ui_base.hpp"
+// forward declarations
+struct ID2D1RenderTarget;
+
namespace cru::ui {
class Control;
}
@@ -70,15 +72,14 @@ class RenderObject : public Object {
virtual void OnSizeChanged(const Size& old_size, const Size& new_size);
+ virtual void OnMeasureCore(const Size& available_size);
+ virtual void OnLayoutCore(const Rect& rect);
virtual Size OnMeasureContent(const Size& available_size) = 0;
virtual void OnLayoutContent(const Rect& content_rect) = 0;
private:
void SetParent(RenderObject* new_parent);
- void OnMeasureCore(const Size& available_size);
- void OnLayoutCore(const Rect& rect);
-
private:
Control* control_ = nullptr;