From 4a30bf58a48ed6f31f4c53473e8de70a8cd819da Mon Sep 17 00:00:00 2001 From: Yuqian Yang Date: Sat, 6 Dec 2025 20:06:10 +0800 Subject: Fix SDL popup window. --- include/cru/ui/controls/Control.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'include/cru/ui/controls/Control.h') diff --git a/include/cru/ui/controls/Control.h b/include/cru/ui/controls/Control.h index 8cd7a375..aa1cef8a 100644 --- a/include/cru/ui/controls/Control.h +++ b/include/cru/ui/controls/Control.h @@ -12,6 +12,11 @@ namespace cru::ui::controls { +struct ControlHostChangeEventArgs { + ControlHost* old_host; + ControlHost* new_host; +}; + /** * \remarks If you want to write a new control. You should override following * methods: @@ -143,6 +148,8 @@ class CRU_UI_API Control : public Object, CRU_DEFINE_ROUTED_EVENT(GainFocus, events::FocusChangeEventArgs) CRU_DEFINE_ROUTED_EVENT(LoseFocus, events::FocusChangeEventArgs) + CRU_DEFINE_EVENT(ControlHostChange, const ControlHostChangeEventArgs&) + //*************** region: tree *************** protected: virtual void OnParentChanged(Control* old_parent, Control* new_parent); -- cgit v1.2.3