mirror of
https://github.com/Dark98/threeSD.git
synced 2026-07-06 00:38:55 +00:00
Add the new contents to custom config
This commit is contained in:
@@ -57,7 +57,7 @@ MainDialog::MainDialog(QWidget* parent) : QDialog(parent), ui(std::make_unique<U
|
|||||||
});
|
});
|
||||||
|
|
||||||
// Field 3: Is file
|
// Field 3: Is file
|
||||||
const std::array<std::tuple<QLineEdit*, QToolButton*, int>, 7> fields{{
|
const std::array<std::tuple<QLineEdit*, QToolButton*, int>, 9> fields{{
|
||||||
{ui->sdmcPath, ui->sdmcPathExplore, 0},
|
{ui->sdmcPath, ui->sdmcPathExplore, 0},
|
||||||
{ui->userPath, ui->userPathExplore, 0},
|
{ui->userPath, ui->userPathExplore, 0},
|
||||||
{ui->movableSedPath, ui->movableSedExplore, 1},
|
{ui->movableSedPath, ui->movableSedExplore, 1},
|
||||||
@@ -65,6 +65,8 @@ MainDialog::MainDialog(QWidget* parent) : QDialog(parent), ui(std::make_unique<U
|
|||||||
{ui->safeModeFirmPath, ui->safeModeFirmExplore, 0},
|
{ui->safeModeFirmPath, ui->safeModeFirmExplore, 0},
|
||||||
{ui->seeddbPath, ui->seeddbExplore, 1},
|
{ui->seeddbPath, ui->seeddbExplore, 1},
|
||||||
{ui->secretSectorPath, ui->secretSectorExplore, 1},
|
{ui->secretSectorPath, ui->secretSectorExplore, 1},
|
||||||
|
{ui->configSavegamePath, ui->configSavegameExplore, 1},
|
||||||
|
{ui->systemArchivesPath, ui->systemArchivesExplore, 0},
|
||||||
}};
|
}};
|
||||||
|
|
||||||
// TODO: better handling (filter)
|
// TODO: better handling (filter)
|
||||||
@@ -119,6 +121,8 @@ void MainDialog::LoadPresetConfig() {
|
|||||||
ui->safeModeFirmPath->setText(QString{});
|
ui->safeModeFirmPath->setText(QString{});
|
||||||
ui->seeddbPath->setText(QString{});
|
ui->seeddbPath->setText(QString{});
|
||||||
ui->secretSectorPath->setText(QString{});
|
ui->secretSectorPath->setText(QString{});
|
||||||
|
ui->configSavegamePath->setText(QString{});
|
||||||
|
ui->systemArchivesPath->setText(QString{});
|
||||||
|
|
||||||
ui->advancedButton->setVisible(false);
|
ui->advancedButton->setVisible(false);
|
||||||
ShowAdvanced();
|
ShowAdvanced();
|
||||||
@@ -157,6 +161,8 @@ void MainDialog::ShowAdvanced() {
|
|||||||
ui->safeModeFirmPath->setText(QString::fromStdString(config.safe_mode_firm_path));
|
ui->safeModeFirmPath->setText(QString::fromStdString(config.safe_mode_firm_path));
|
||||||
ui->seeddbPath->setText(QString::fromStdString(config.seed_db_path));
|
ui->seeddbPath->setText(QString::fromStdString(config.seed_db_path));
|
||||||
ui->secretSectorPath->setText(QString::fromStdString(config.secret_sector_path));
|
ui->secretSectorPath->setText(QString::fromStdString(config.secret_sector_path));
|
||||||
|
ui->configSavegamePath->setText(QString::fromStdString(config.config_savegame_path));
|
||||||
|
ui->systemArchivesPath->setText(QString::fromStdString(config.system_archives_path));
|
||||||
}
|
}
|
||||||
|
|
||||||
void MainDialog::HideAdvanced() {
|
void MainDialog::HideAdvanced() {
|
||||||
@@ -180,6 +186,8 @@ Core::Config MainDialog::GetCurrentConfig() {
|
|||||||
/*safe_mode_firm_path*/ ui->safeModeFirmPath->text().toStdString(),
|
/*safe_mode_firm_path*/ ui->safeModeFirmPath->text().toStdString(),
|
||||||
/*seed_db_path*/ ui->seeddbPath->text().toStdString(),
|
/*seed_db_path*/ ui->seeddbPath->text().toStdString(),
|
||||||
/*secret_sector_path*/ ui->secretSectorPath->text().toStdString(),
|
/*secret_sector_path*/ ui->secretSectorPath->text().toStdString(),
|
||||||
|
/*config_savegame_path*/ ui->configSavegamePath->text().toStdString(),
|
||||||
|
/*system_archives_path*/ ui->systemArchivesPath->text().toStdString(),
|
||||||
};
|
};
|
||||||
return config;
|
return config;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -208,6 +208,40 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="7" column="0">
|
||||||
|
<widget class="QLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string>Config savegame</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="7" column="1">
|
||||||
|
<widget class="QLineEdit" name="configSavegamePath"/>
|
||||||
|
</item>
|
||||||
|
<item row="7" column="2">
|
||||||
|
<widget class="QToolButton" name="configSavegameExplore">
|
||||||
|
<property name="text">
|
||||||
|
<string>...</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="0">
|
||||||
|
<widget class="QLabel">
|
||||||
|
<property name="text">
|
||||||
|
<string>System archives</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="1">
|
||||||
|
<widget class="QLineEdit" name="systemArchivesPath"/>
|
||||||
|
</item>
|
||||||
|
<item row="8" column="2">
|
||||||
|
<widget class="QToolButton" name="systemArchivesExplore">
|
||||||
|
<property name="text">
|
||||||
|
<string>...</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
Reference in New Issue
Block a user