mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-03 21:41:26 +12:00
patch manager: Skip legacy patch.yml in the GUI
The legacy patches aren't supposed to be shown in the GUI anyway.
This commit is contained in:
parent
8659994b2c
commit
1974911a71
1 changed files with 7 additions and 15 deletions
|
@ -87,28 +87,20 @@ void patch_manager_dialog::load_patches()
|
||||||
{
|
{
|
||||||
m_map.clear();
|
m_map.clear();
|
||||||
|
|
||||||
// NOTE: Make sure to load these in the same order as they are applied on boot
|
// NOTE: Make sure these paths are loaded in the same order as they are applied on boot
|
||||||
|
|
||||||
// Legacy path (in case someone puts it there)
|
|
||||||
patch_engine::load(m_map, fs::get_config_dir() + "patch.yml");
|
|
||||||
|
|
||||||
// New paths
|
|
||||||
const std::string imports_path = patch_engine::get_imported_patch_path();
|
|
||||||
const std::string patches_path = fs::get_config_dir() + "patches/";
|
const std::string patches_path = fs::get_config_dir() + "patches/";
|
||||||
const QStringList filters = QStringList() << "*_patch.yml";
|
const QStringList filters = QStringList() << "*_patch.yml";
|
||||||
const QStringList path_list = QDir(QString::fromStdString(patches_path)).entryList(filters);
|
|
||||||
|
|
||||||
patch_engine::load(m_map, patches_path + "patch.yml");
|
QStringList path_list;
|
||||||
patch_engine::load(m_map, imports_path);
|
path_list << "patch.yml";
|
||||||
|
path_list << "imported_patch.yml";
|
||||||
|
path_list << QDir(QString::fromStdString(patches_path)).entryList(filters);
|
||||||
|
path_list.removeDuplicates(); // make sure to load patch.yml and imported_patch.yml only once
|
||||||
|
|
||||||
for (const auto& path : path_list)
|
for (const auto& path : path_list)
|
||||||
{
|
{
|
||||||
const std::string patch_path = patches_path + path.toStdString();
|
patch_engine::load(m_map, patches_path + path.toStdString());
|
||||||
|
|
||||||
if (patch_path != imports_path)
|
|
||||||
{
|
|
||||||
patch_engine::load(m_map, patch_path);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue