aboutsummaryrefslogtreecommitdiff
path: root/src/ui/render/border_render_object.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/render/border_render_object.cpp')
-rw-r--r--src/ui/render/border_render_object.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/ui/render/border_render_object.cpp b/src/ui/render/border_render_object.cpp
index 16f2828a..5b6cdb3c 100644
--- a/src/ui/render/border_render_object.cpp
+++ b/src/ui/render/border_render_object.cpp
@@ -39,6 +39,15 @@ void BorderRenderObject::Draw(platform::graph::IPainter* painter) {
foreground_brush_.get());
}
+void BorderRenderObject::SetBorderStyle(const BorderStyle& style) {
+ border_brush_ = style.border_brush;
+ border_thickness_ = style.border_thickness;
+ border_radius_ = style.border_radius;
+ foreground_brush_ = style.foreground_brush;
+ background_brush_ = style.background_brush;
+ InvalidateLayout();
+}
+
RenderObject* BorderRenderObject::HitTest(const Point& point) {
if (const auto child = GetChild()) {
auto offset = child->GetOffset();