From 9a3bbde2d1c5a4de9906d1856de9d80a5d140c16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Va=CC=81clav=20Slavi=CC=81k?= Date: Mon, 19 Apr 2021 13:53:15 +0200 Subject: [PATCH] Generalize wxBookCtrlBase::m_bookctrl to wxWindow The field is used for common placement and sizing logic in notebook-like controls that have a "controller buddy" control. Its use isn't wxControl-specific and only relies on wxWindow API, so the restriction to wxControl-inherited types is arbitrary. Change the type to the more general wxWindow* pointer. In practical terms, this allows derived classes to use e.g. wxNativeWindow as the controller buddy. --- include/wx/bookctrl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/wx/bookctrl.h b/include/wx/bookctrl.h index 638f7c6436..f77f277ca6 100644 --- a/include/wx/bookctrl.h +++ b/include/wx/bookctrl.h @@ -339,7 +339,7 @@ protected: void OnSize(wxSizeEvent& event); // controller buddy if available, NULL otherwise (usually for native book controls like wxNotebook) - wxControl *m_bookctrl; + wxWindow *m_bookctrl; // Whether to shrink to fit current page bool m_fitToCurrentPage;