ShatteredPrism/launcher/ui/setupwizard/AutoJavaWizardPage.cpp
Trial97 c85294af9d
Improve wizzard page
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
2024-09-13 19:33:24 +03:00

34 lines
728 B
C++

#include "AutoJavaWizardPage.h"
#include "ui_AutoJavaWizardPage.h"
#include "Application.h"
AutoJavaWizardPage::AutoJavaWizardPage(QWidget* parent) : BaseWizardPage(parent), ui(new Ui::AutoJavaWizardPage)
{
ui->setupUi(this);
}
AutoJavaWizardPage::~AutoJavaWizardPage()
{
delete ui;
}
void AutoJavaWizardPage::initializePage() {}
bool AutoJavaWizardPage::validatePage()
{
auto s = APPLICATION->settings();
if (!ui->previousSettingsRadioButton->isChecked()) {
s->set("AutomaticJavaSwitch", true);
s->set("AutomaticJavaDownload", true);
}
s->set("UserAskedAboutAutomaticJavaDownload", true);
return true;
}
void AutoJavaWizardPage::retranslate()
{
ui->retranslateUi(this);
}