Don't override Refresh() in wxStatusBar under wxQt

This is not necessary and, more importantly, results in a crash if you try
to recreate the status bar (which can be seen in the statbar example)

Also remove leftover QList declaration
This commit is contained in:
ali kettab 2023-11-20 13:34:25 +01:00
parent e9dd395215
commit d3bdf486b3
2 changed files with 0 additions and 12 deletions

View file

@ -13,8 +13,6 @@
class QLabel;
class QStatusBar;
template < class T > class QList;
class WXDLLIMPEXP_CORE wxStatusBar : public wxStatusBarBase
{
public:
@ -31,8 +29,6 @@ public:
virtual void SetMinHeight(int height) override;
virtual int GetBorderX() const override;
virtual int GetBorderY() const override;
virtual void Refresh( bool eraseBackground = true,
const wxRect *rect = nullptr ) override;
QStatusBar *GetQStatusBar() const { return m_qtStatusBar; }
QWidget *GetHandle() const override;

View file

@ -94,14 +94,6 @@ void wxStatusBar::DoUpdateStatusText(int number)
m_qtPanes[number]->setText( wxQtConvertString( m_panes[number].GetText() ) );
}
// Called each time number/size of panes changes
void wxStatusBar::Refresh( bool eraseBackground, const wxRect *rect )
{
UpdateFields();
wxWindow::Refresh( eraseBackground, rect );
}
void wxStatusBar::Init()
{
m_qtStatusBar = nullptr;