pollymc/launcher/setupwizard/BaseWizardPage.h

34 lines
603 B
C
Raw Normal View History

2017-01-05 08:35:08 +05:30
#pragma once
#include <QWizardPage>
#include <QEvent>
class BaseWizardPage : public QWizardPage
{
public:
2018-07-15 18:21:05 +05:30
explicit BaseWizardPage(QWidget *parent = Q_NULLPTR)
: QWizardPage(parent)
{
}
virtual ~BaseWizardPage() {};
2017-01-05 08:35:08 +05:30
2018-07-15 18:21:05 +05:30
virtual bool wantsRefreshButton()
{
return false;
}
virtual void refresh()
{
}
2017-01-05 08:35:08 +05:30
protected:
2018-07-15 18:21:05 +05:30
virtual void retranslate() = 0;
void changeEvent(QEvent * event) override
{
if (event->type() == QEvent::LanguageChange)
{
retranslate();
}
QWizardPage::changeEvent(event);
}
2017-01-05 08:35:08 +05:30
};