mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-25 11:34:55 +00:00
more setting
This commit is contained in:
parent
a01d34cb43
commit
5181ff36ff
@ -50,7 +50,6 @@ static bool isMotionControlsEnabled = true;
|
|||||||
static bool isDebugDump = false;
|
static bool isDebugDump = false;
|
||||||
static bool isShaderDebug = false;
|
static bool isShaderDebug = false;
|
||||||
static bool isShowSplash = false;
|
static bool isShowSplash = false;
|
||||||
static bool isAlwaysShowChangelog = false;
|
|
||||||
static std::string isSideTrophy = "right";
|
static std::string isSideTrophy = "right";
|
||||||
static bool isNullGpu = false;
|
static bool isNullGpu = false;
|
||||||
static bool shouldCopyGPUBuffers = false;
|
static bool shouldCopyGPUBuffers = false;
|
||||||
@ -243,10 +242,6 @@ bool showSplash() {
|
|||||||
return isShowSplash;
|
return isShowSplash;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool alwaysShowChangelog() {
|
|
||||||
return isAlwaysShowChangelog;
|
|
||||||
}
|
|
||||||
|
|
||||||
std::string sideTrophy() {
|
std::string sideTrophy() {
|
||||||
return isSideTrophy;
|
return isSideTrophy;
|
||||||
}
|
}
|
||||||
@ -347,9 +342,6 @@ void setShowSplash(bool enable) {
|
|||||||
isShowSplash = enable;
|
isShowSplash = enable;
|
||||||
}
|
}
|
||||||
|
|
||||||
void setAlwaysShowChangelog(bool enable) {
|
|
||||||
isAlwaysShowChangelog = enable;
|
|
||||||
}
|
|
||||||
|
|
||||||
void setSideTrophy(std::string side) {
|
void setSideTrophy(std::string side) {
|
||||||
isSideTrophy = side;
|
isSideTrophy = side;
|
||||||
@ -630,7 +622,6 @@ void load(const std::filesystem::path& path) {
|
|||||||
updateChannel = toml::find_or<std::string>(general, "updateChannel", "Nightly");
|
updateChannel = toml::find_or<std::string>(general, "updateChannel", "Nightly");
|
||||||
}
|
}
|
||||||
isShowSplash = toml::find_or<bool>(general, "showSplash", true);
|
isShowSplash = toml::find_or<bool>(general, "showSplash", true);
|
||||||
isAlwaysShowChangelog = toml::find_or<bool>(general, "alwaysShowChangelog", false);
|
|
||||||
isSideTrophy = toml::find_or<std::string>(general, "sideTrophy", "right");
|
isSideTrophy = toml::find_or<std::string>(general, "sideTrophy", "right");
|
||||||
compatibilityData = toml::find_or<bool>(general, "compatibilityEnabled", false);
|
compatibilityData = toml::find_or<bool>(general, "compatibilityEnabled", false);
|
||||||
checkCompatibilityOnStartup =
|
checkCompatibilityOnStartup =
|
||||||
@ -810,7 +801,6 @@ void save(const std::filesystem::path& path) {
|
|||||||
data["General"]["updateChannel"] = updateChannel;
|
data["General"]["updateChannel"] = updateChannel;
|
||||||
data["General"]["chooseHomeTab"] = chooseHomeTab;
|
data["General"]["chooseHomeTab"] = chooseHomeTab;
|
||||||
data["General"]["showSplash"] = isShowSplash;
|
data["General"]["showSplash"] = isShowSplash;
|
||||||
data["General"]["alwaysShowChangelog"] = isAlwaysShowChangelog;
|
|
||||||
data["General"]["sideTrophy"] = isSideTrophy;
|
data["General"]["sideTrophy"] = isSideTrophy;
|
||||||
data["General"]["compatibilityEnabled"] = compatibilityData;
|
data["General"]["compatibilityEnabled"] = compatibilityData;
|
||||||
data["General"]["checkCompatibilityOnStartup"] = checkCompatibilityOnStartup;
|
data["General"]["checkCompatibilityOnStartup"] = checkCompatibilityOnStartup;
|
||||||
@ -954,7 +944,6 @@ void setDefaultValues() {
|
|||||||
isDebugDump = false;
|
isDebugDump = false;
|
||||||
isShaderDebug = false;
|
isShaderDebug = false;
|
||||||
isShowSplash = false;
|
isShowSplash = false;
|
||||||
isAlwaysShowChangelog = false;
|
|
||||||
isSideTrophy = "right";
|
isSideTrophy = "right";
|
||||||
isNullGpu = false;
|
isNullGpu = false;
|
||||||
shouldDumpShaders = false;
|
shouldDumpShaders = false;
|
||||||
|
@ -63,7 +63,6 @@ bool allowHDR();
|
|||||||
bool debugDump();
|
bool debugDump();
|
||||||
bool collectShadersForDebug();
|
bool collectShadersForDebug();
|
||||||
bool showSplash();
|
bool showSplash();
|
||||||
bool alwaysShowChangelog();
|
|
||||||
std::string sideTrophy();
|
std::string sideTrophy();
|
||||||
bool nullGpu();
|
bool nullGpu();
|
||||||
bool copyGPUCmdBuffers();
|
bool copyGPUCmdBuffers();
|
||||||
@ -76,7 +75,6 @@ u32 vblankDiv();
|
|||||||
void setDebugDump(bool enable);
|
void setDebugDump(bool enable);
|
||||||
void setCollectShaderForDebug(bool enable);
|
void setCollectShaderForDebug(bool enable);
|
||||||
void setShowSplash(bool enable);
|
void setShowSplash(bool enable);
|
||||||
void setAlwaysShowChangelog(bool enable);
|
|
||||||
void setSideTrophy(std::string side);
|
void setSideTrophy(std::string side);
|
||||||
void setNullGpu(bool enable);
|
void setNullGpu(bool enable);
|
||||||
void setAllowHDR(bool enable);
|
void setAllowHDR(bool enable);
|
||||||
|
@ -275,7 +275,7 @@ void CheckUpdate::setupUI(const QString& downloadUrl, const QString& latestDate,
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
if (Config::alwaysShowChangelog()) {
|
if (m_gui_settings->GetValue(gui::gen_showChangeLog).toBool()) {
|
||||||
requestChangelog(currentRev, latestRev, downloadUrl, latestDate, currentDate);
|
requestChangelog(currentRev, latestRev, downloadUrl, latestDate, currentDate);
|
||||||
textField->setVisible(true);
|
textField->setVisible(true);
|
||||||
toggleButton->setText(tr("Hide Changelog"));
|
toggleButton->setText(tr("Hide Changelog"));
|
||||||
|
@ -15,6 +15,7 @@ const QString game_grid = "game_grid";
|
|||||||
|
|
||||||
// general
|
// general
|
||||||
const gui_value gen_checkForUpdates = gui_value(general, "checkForUpdates", false);
|
const gui_value gen_checkForUpdates = gui_value(general, "checkForUpdates", false);
|
||||||
|
const gui_value gen_showChangeLog = gui_value(general, "showChangeLog", false);
|
||||||
|
|
||||||
// main window settings
|
// main window settings
|
||||||
const gui_value mw_geometry = gui_value(main_window, "geometry", QByteArray());
|
const gui_value mw_geometry = gui_value(main_window, "geometry", QByteArray());
|
||||||
|
@ -181,8 +181,8 @@ SettingsDialog::SettingsDialog(std::shared_ptr<gui_settings> gui_settings,
|
|||||||
m_gui_settings->SetValue(gui::gen_checkForUpdates, state == Qt::Checked);
|
m_gui_settings->SetValue(gui::gen_checkForUpdates, state == Qt::Checked);
|
||||||
});
|
});
|
||||||
|
|
||||||
connect(ui->changelogCheckBox, &QCheckBox::stateChanged, this,
|
connect(ui->changelogCheckBox, &QCheckBox::stateChanged, this, [this](int state) { m_gui_settings->SetValue(gui::gen_showChangeLog,state == Qt::Checked);
|
||||||
[](int state) { Config::setAlwaysShowChangelog(state == Qt::Checked); });
|
});
|
||||||
#else
|
#else
|
||||||
connect(ui->updateCheckBox, &QCheckBox::checkStateChanged, this,
|
connect(ui->updateCheckBox, &QCheckBox::checkStateChanged, this,
|
||||||
[this](Qt::CheckState state) {
|
[this](Qt::CheckState state) {
|
||||||
@ -190,7 +190,9 @@ SettingsDialog::SettingsDialog(std::shared_ptr<gui_settings> gui_settings,
|
|||||||
});
|
});
|
||||||
|
|
||||||
connect(ui->changelogCheckBox, &QCheckBox::checkStateChanged, this,
|
connect(ui->changelogCheckBox, &QCheckBox::checkStateChanged, this,
|
||||||
[](Qt::CheckState state) { Config::setAlwaysShowChangelog(state == Qt::Checked); });
|
[this](Qt::CheckState state) {
|
||||||
|
m_gui_settings->SetValue(gui::gen_showChangeLog, state == Qt::Checked);
|
||||||
|
});
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
connect(ui->updateComboBox, &QComboBox::currentTextChanged, this,
|
connect(ui->updateComboBox, &QComboBox::currentTextChanged, this,
|
||||||
@ -792,7 +794,7 @@ void SettingsDialog::UpdateSettings() {
|
|||||||
Config::setCollectShaderForDebug(ui->collectShaderCheckBox->isChecked());
|
Config::setCollectShaderForDebug(ui->collectShaderCheckBox->isChecked());
|
||||||
Config::setCopyGPUCmdBuffers(ui->copyGPUBuffersCheckBox->isChecked());
|
Config::setCopyGPUCmdBuffers(ui->copyGPUBuffersCheckBox->isChecked());
|
||||||
m_gui_settings->SetValue(gui::gen_checkForUpdates, ui->updateCheckBox->isChecked());
|
m_gui_settings->SetValue(gui::gen_checkForUpdates, ui->updateCheckBox->isChecked());
|
||||||
Config::setAlwaysShowChangelog(ui->changelogCheckBox->isChecked());
|
m_gui_settings->SetValue(gui::gen_showChangeLog,ui->changelogCheckBox->isChecked());
|
||||||
Config::setUpdateChannel(channelMap.value(ui->updateComboBox->currentText()).toStdString());
|
Config::setUpdateChannel(channelMap.value(ui->updateComboBox->currentText()).toStdString());
|
||||||
Config::setChooseHomeTab(
|
Config::setChooseHomeTab(
|
||||||
chooseHomeTabMap.value(ui->chooseHomeTabComboBox->currentText()).toStdString());
|
chooseHomeTabMap.value(ui->chooseHomeTabComboBox->currentText()).toStdString());
|
||||||
@ -877,4 +879,5 @@ void SettingsDialog::setDefaultValues() {
|
|||||||
m_gui_settings->SetValue(gui::gl_playBackgroundMusic, false);
|
m_gui_settings->SetValue(gui::gl_playBackgroundMusic, false);
|
||||||
m_gui_settings->SetValue(gui::gl_backgroundMusicVolume, 50);
|
m_gui_settings->SetValue(gui::gl_backgroundMusicVolume, 50);
|
||||||
m_gui_settings->SetValue(gui::gen_checkForUpdates, false);
|
m_gui_settings->SetValue(gui::gen_checkForUpdates, false);
|
||||||
|
m_gui_settings->SetValue(gui::gen_showChangeLog, false);
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user