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.
This commit is contained in:
Václav Slavík 2021-04-19 13:53:15 +02:00
parent cb8d7c533f
commit 9a3bbde2d1

View File

@ -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;