From 6b4edc9be8ec556147c195cf2047d92b9439efd7 Mon Sep 17 00:00:00 2001 From: Yuqian Yang Date: Tue, 18 Nov 2025 00:46:27 +0800 Subject: Bring back ControlHost and refactor tree management of control. --- include/cru/ui/controls/CheckBox.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'include/cru/ui/controls/CheckBox.h') diff --git a/include/cru/ui/controls/CheckBox.h b/include/cru/ui/controls/CheckBox.h index 8a2c84a0..6f4eae2e 100644 --- a/include/cru/ui/controls/CheckBox.h +++ b/include/cru/ui/controls/CheckBox.h @@ -1,13 +1,13 @@ #pragma once #include "../helper/ClickDetector.h" #include "../render/BorderRenderObject.h" +#include "Control.h" #include "IBorderControl.h" #include "ICheckableControl.h" #include "IClickableControl.h" -#include "NoChildControl.h" namespace cru::ui::controls { -class CRU_UI_API CheckBox : public NoChildControl, +class CRU_UI_API CheckBox : public Control, public virtual IBorderControl, public virtual ICheckableControl, public virtual IClickableControl { @@ -17,7 +17,9 @@ class CRU_UI_API CheckBox : public NoChildControl, CheckBox(); ~CheckBox() override; - std::string GetControlType() const override { return std::string(kControlType); } + std::string GetControlType() const override { + return std::string(kControlType); + } render::RenderObject* GetRenderObject() const override { return container_render_object_.get(); -- cgit v1.2.3