diff --git a/include/wx/generic/stattextg.h b/include/wx/generic/stattextg.h index ef225e12b2..02860ea951 100644 --- a/include/wx/generic/stattextg.h +++ b/include/wx/generic/stattextg.h @@ -44,8 +44,8 @@ public: const wxString& name = wxStaticTextNameStr); +protected: virtual wxSize DoGetBestClientSize() const; - virtual wxSize DoGetBestSize() const; virtual void SetLabel(const wxString& label); virtual bool SetFont(const wxFont &font); @@ -53,11 +53,11 @@ public: virtual wxString DoGetLabel() const { return m_label; } virtual void DoSetLabel(const wxString& label); -protected: - void OnPaint(wxPaintEvent& event); void DoSetSize(int x, int y, int width, int height, int sizeFlags); private: + void OnPaint(wxPaintEvent& event); + wxString m_label; int m_mnemonic; diff --git a/src/generic/stattextg.cpp b/src/generic/stattextg.cpp index 2047f27d0e..d4cd0c364a 100644 --- a/src/generic/stattextg.cpp +++ b/src/generic/stattextg.cpp @@ -82,14 +82,6 @@ wxSize wxGenericStaticText::DoGetBestClientSize() const return wxSize(width, height); } -wxSize wxGenericStaticText::DoGetBestSize() const -{ - wxSize ret = DoGetBestClientSize(); - CacheBestSize(ret); - return ret; -} - - void wxGenericStaticText::SetLabel(const wxString& label) { wxControl::SetLabel(label);