summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorlat9nq <22451773+lat9nq@users.noreply.github.com>2023-05-06 05:31:24 +0200
committerlat9nq <22451773+lat9nq@users.noreply.github.com>2023-07-21 16:56:07 +0200
commitb11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd (patch)
treeef4ec60784252a5bf5551a3b289a8e4a31872762 /src
parentconfiguration: Add base class to tabs (diff)
downloadyuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar.gz
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar.bz2
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar.lz
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar.xz
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.tar.zst
yuzu-b11b4be7cb764bc0c1aa6c563ccf41a3d1b335dd.zip
Diffstat (limited to 'src')
-rw-r--r--src/yuzu/configuration/configure_per_game.cpp18
-rw-r--r--src/yuzu/configuration/configure_per_game.h3
2 files changed, 11 insertions, 10 deletions
diff --git a/src/yuzu/configuration/configure_per_game.cpp b/src/yuzu/configuration/configure_per_game.cpp
index c54d7e76f..7ec0bf9d3 100644
--- a/src/yuzu/configuration/configure_per_game.cpp
+++ b/src/yuzu/configuration/configure_per_game.cpp
@@ -42,22 +42,22 @@ ConfigurePerGame::ConfigurePerGame(QWidget* parent, u64 title_id_, const std::st
std::vector<VkDeviceInfo::Record>& vk_device_records,
Core::System& system_)
: QDialog(parent), ui(std::make_unique<Ui::ConfigurePerGame>()), title_id{title_id_},
- system{system_}, group{std::make_shared<std::forward_list<ConfigurationShared::Tab*>>()} {
+ system{system_}, tab_group{std::make_shared<std::forward_list<ConfigurationShared::Tab*>>()} {
const auto file_path = std::filesystem::path(Common::FS::ToU8String(file_name));
const auto config_file_name = title_id == 0 ? Common::FS::PathToUTF8String(file_path.filename())
: fmt::format("{:016X}", title_id);
game_config = std::make_unique<Config>(config_file_name, Config::ConfigType::PerGameConfig);
addons_tab = std::make_unique<ConfigurePerGameAddons>(system_, this);
- audio_tab = std::make_unique<ConfigureAudio>(system_, group, this);
- cpu_tab = std::make_unique<ConfigureCpu>(system_, group, this);
- general_tab = std::make_unique<ConfigureGeneral>(system_, group, this);
- graphics_advanced_tab = std::make_unique<ConfigureGraphicsAdvanced>(system_, group, this);
+ audio_tab = std::make_unique<ConfigureAudio>(system_, tab_group, this);
+ cpu_tab = std::make_unique<ConfigureCpu>(system_, tab_group, this);
+ general_tab = std::make_unique<ConfigureGeneral>(system_, tab_group, this);
+ graphics_advanced_tab = std::make_unique<ConfigureGraphicsAdvanced>(system_, tab_group, this);
graphics_tab = std::make_unique<ConfigureGraphics>(
- system_, vk_device_records, [&]() { graphics_advanced_tab->ExposeComputeOption(); }, group,
- this);
+ system_, vk_device_records, [&]() { graphics_advanced_tab->ExposeComputeOption(); },
+ tab_group, this);
input_tab = std::make_unique<ConfigureInputPerGame>(system_, game_config.get(), this);
- system_tab = std::make_unique<ConfigureSystem>(system_, group, this);
+ system_tab = std::make_unique<ConfigureSystem>(system_, tab_group, this);
ui->setupUi(this);
@@ -90,7 +90,7 @@ ConfigurePerGame::ConfigurePerGame(QWidget* parent, u64 title_id_, const std::st
ConfigurePerGame::~ConfigurePerGame() = default;
void ConfigurePerGame::ApplyConfiguration() {
- for (const auto tab : *group) {
+ for (const auto tab : *tab_group) {
tab->ApplyConfiguration();
}
addons_tab->ApplyConfiguration();
diff --git a/src/yuzu/configuration/configure_per_game.h b/src/yuzu/configuration/configure_per_game.h
index 5326e70e6..9fceff414 100644
--- a/src/yuzu/configuration/configure_per_game.h
+++ b/src/yuzu/configuration/configure_per_game.h
@@ -75,7 +75,8 @@ private:
std::unique_ptr<Config> game_config;
Core::System& system;
- std::shared_ptr<std::forward_list<ConfigurationShared::Tab*>> group;
+ std::shared_ptr<std::forward_list<ConfigurationShared::Tab*>> tab_group;
+
std::unique_ptr<ConfigurePerGameAddons> addons_tab;
std::unique_ptr<ConfigureAudio> audio_tab;
std::unique_ptr<ConfigureCpu> cpu_tab;