From dfd042c809a061efa9b1690384e9e41d635294b0 Mon Sep 17 00:00:00 2001 From: lizzie Date: Thu, 4 Dec 2025 07:29:41 +0100 Subject: [PATCH] [qt] remove unused config migrator (#3130) Signed-off-by: lizzie Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3130 Reviewed-by: Caio Oliveira Reviewed-by: crueter Co-authored-by: lizzie Co-committed-by: lizzie --- src/yuzu/main_window.cpp | 29 ----------------------------- 1 file changed, 29 deletions(-) diff --git a/src/yuzu/main_window.cpp b/src/yuzu/main_window.cpp index a301ae077e..d0ece67028 100644 --- a/src/yuzu/main_window.cpp +++ b/src/yuzu/main_window.cpp @@ -571,8 +571,6 @@ MainWindow::MainWindow(bool has_broken_vulkan) connect(&update_input_timer, &QTimer::timeout, this, &MainWindow::UpdateInputDrivers); update_input_timer.start(); - MigrateConfigFiles(); - if (has_broken_vulkan) { UISettings::values.has_broken_vulkan = true; @@ -4122,33 +4120,6 @@ void MainWindow::OnCaptureScreenshot() { render_window->CaptureScreenshot(filename); } -// TODO: Written 2020-10-01: Remove per-game config migration code when it is irrelevant -void MainWindow::MigrateConfigFiles() { - const auto config_dir_fs_path = Common::FS::GetEdenPath(Common::FS::EdenPath::ConfigDir); - const QDir config_dir = - QDir(QString::fromStdString(Common::FS::PathToUTF8String(config_dir_fs_path))); - const QStringList config_dir_list = config_dir.entryList(QStringList(QStringLiteral("*.ini"))); - - if (!Common::FS::CreateDirs(config_dir_fs_path / "custom")) { - LOG_ERROR(Frontend, "Failed to create new config file directory"); - } - - for (auto it = config_dir_list.constBegin(); it != config_dir_list.constEnd(); ++it) { - const auto filename = it->toStdString(); - if (filename.find_first_not_of("0123456789abcdefACBDEF", 0) < 16) { - continue; - } - const auto origin = config_dir_fs_path / filename; - const auto destination = config_dir_fs_path / "custom" / filename; - LOG_INFO(Frontend, "Migrating config file from {} to {}", origin.string(), - destination.string()); - if (!Common::FS::RenameFile(origin, destination)) { - // Delete the old config file if one already exists in the new location. - Common::FS::RemoveFile(origin); - } - } -} - #ifdef ENABLE_UPDATE_CHECKER void MainWindow::OnEmulatorUpdateAvailable() { QString version_string = update_future.result();