Rename window modes and map

This commit is contained in:
Jarred Wilson 2025-02-20 16:15:48 +00:00
parent 1572e471fb
commit efd7790aba
2 changed files with 6 additions and 6 deletions

View File

@ -60,7 +60,7 @@ const QVector<int> languageIndexes = {21, 23, 14, 6, 18, 1, 12, 22, 2, 4, 25, 2
15, 16, 17, 7, 26, 8, 11, 20, 3, 13, 27, 10, 19, 30, 28}; 15, 16, 17, 7, 26, 8, 11, 20, 3, 13, 27, 10, 19, 30, 28};
QMap<QString, QString> channelMap; QMap<QString, QString> channelMap;
QMap<QString, QString> logTypeMap; QMap<QString, QString> logTypeMap;
QMap<QString, QString> fullscreenModeMap; QMap<QString, QString> screenModeMap;
QMap<QString, QString> chooseHomeTabMap; QMap<QString, QString> chooseHomeTabMap;
SettingsDialog::SettingsDialog(std::span<const QString> physical_devices, SettingsDialog::SettingsDialog(std::span<const QString> physical_devices,
@ -77,7 +77,7 @@ SettingsDialog::SettingsDialog(std::span<const QString> physical_devices,
channelMap = {{tr("Release"), "Release"}, {tr("Nightly"), "Nightly"}}; channelMap = {{tr("Release"), "Release"}, {tr("Nightly"), "Nightly"}};
logTypeMap = {{tr("async"), "async"}, {tr("sync"), "sync"}}; logTypeMap = {{tr("async"), "async"}, {tr("sync"), "sync"}};
fullscreenModeMap = {{tr("Borderless"), "Borderless"}, {tr("Fullscreen"), "Fullscreen"}}; screenModeMap = {{tr("Borderless"), "Borderless"}, {tr("Windowed"), "Windowed"}};
chooseHomeTabMap = {{tr("General"), "General"}, {tr("GUI"), "GUI"}, chooseHomeTabMap = {{tr("General"), "General"}, {tr("GUI"), "GUI"},
{tr("Graphics"), "Graphics"}, {tr("User"), "User"}, {tr("Graphics"), "Graphics"}, {tr("User"), "User"},
{tr("Input"), "Input"}, {tr("Paths"), "Paths"}, {tr("Input"), "Input"}, {tr("Paths"), "Paths"},
@ -382,7 +382,7 @@ void SettingsDialog::LoadValuesFromConfig() {
ui->discordRPCCheckbox->setChecked( ui->discordRPCCheckbox->setChecked(
toml::find_or<bool>(data, "General", "enableDiscordRPC", true)); toml::find_or<bool>(data, "General", "enableDiscordRPC", true));
QString translatedText_FullscreenMode = QString translatedText_FullscreenMode =
fullscreenModeMap.key(QString::fromStdString(Config::getFullscreenMode())); screenModeMap.key(QString::fromStdString(Config::getFullscreenMode()));
ui->displayModeComboBox->setCurrentText(translatedText_FullscreenMode); ui->displayModeComboBox->setCurrentText(translatedText_FullscreenMode);
ui->separateUpdatesCheckBox->setChecked( ui->separateUpdatesCheckBox->setChecked(
toml::find_or<bool>(data, "General", "separateUpdateEnabled", false)); toml::find_or<bool>(data, "General", "separateUpdateEnabled", false));
@ -646,9 +646,9 @@ void SettingsDialog::UpdateSettings() {
const QVector<std::string> TouchPadIndex = {"left", "center", "right", "none"}; const QVector<std::string> TouchPadIndex = {"left", "center", "right", "none"};
Config::setBackButtonBehavior(TouchPadIndex[ui->backButtonBehaviorComboBox->currentIndex()]); Config::setBackButtonBehavior(TouchPadIndex[ui->backButtonBehaviorComboBox->currentIndex()]);
Config::setIsFullscreen(ui->displayModeComboBox->currentText().toStdString() == "Fullscreen"); Config::setIsFullscreen(ui->displayModeComboBox->currentText().toStdString() == "Borderless Windowed");
Config::setFullscreenMode( Config::setFullscreenMode(
fullscreenModeMap.value(ui->displayModeComboBox->currentText()).toStdString()); screenModeMap.value(ui->displayModeComboBox->currentText()).toStdString());
Config::setIsMotionControlsEnabled(ui->motionControlsCheckBox->isChecked()); Config::setIsMotionControlsEnabled(ui->motionControlsCheckBox->isChecked());
Config::setisTrophyPopupDisabled(ui->disableTrophycheckBox->isChecked()); Config::setisTrophyPopupDisabled(ui->disableTrophycheckBox->isChecked());
Config::setPlayBGM(ui->playBGMCheckBox->isChecked()); Config::setPlayBGM(ui->playBGMCheckBox->isChecked());

View File

@ -996,7 +996,7 @@
</item> </item>
<item> <item>
<property name="text"> <property name="text">
<string>Fullscreen</string> <string>Borderless Windowed</string>
</property> </property>
</item> </item>
</widget> </widget>