From: Michael Bedward Date: Thu, 16 Sep 1999 10:32:03 +0000 (+0000) Subject: Added GetMainWidget() to fix bug that was causing crashes under wxMOTIF. X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/7183e38becd5121af4c96ceabd62fa71746442f5 Added GetMainWidget() to fix bug that was causing crashes under wxMOTIF. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3683 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/generic/statline.h b/include/wx/generic/statline.h index d8832381ac..5d3dafa675 100644 --- a/include/wx/generic/statline.h +++ b/include/wx/generic/statline.h @@ -46,6 +46,11 @@ public: long style = wxLI_HORIZONTAL, const wxString &name = wxStaticTextNameStr ); + // it's necessary to override this wxWindow function because we + // will want to return the main widget for m_statbox + // + WXWidget GetMainWidget() const; + protected: // we implement the static line using a static box wxStaticBox *m_statbox; diff --git a/src/generic/statline.cpp b/src/generic/statline.cpp index f6872ff56a..31bbdec49e 100644 --- a/src/generic/statline.cpp +++ b/src/generic/statline.cpp @@ -59,3 +59,9 @@ bool wxStaticLine::Create( wxWindow *parent, return TRUE; } + + +WXWidget wxStaticLine::GetMainWidget() const +{ + return m_statbox->GetMainWidget(); +}