From 6633d7252c0a41144a2f2d54ee3bf3bb322aaadf Mon Sep 17 00:00:00 2001 From: Niram7777 Date: Tue, 5 May 2026 01:21:28 +0200 Subject: [PATCH] Log read setting from old toml outside the [Log] section (#4342) --- src/core/emulator_settings.cpp | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/src/core/emulator_settings.cpp b/src/core/emulator_settings.cpp index 1d371e662..234e8c2ac 100644 --- a/src/core/emulator_settings.cpp +++ b/src/core/emulator_settings.cpp @@ -545,6 +545,29 @@ bool EmulatorSettingsImpl::TransferSettings() { #endif } + if (og_data.contains("General")) { + const toml::value& general = og_data.at("General"); + auto& s = m_log; + + setFromToml(s.filter, general, "logFilter"); + setFromToml(s.skip_duplicate, general, "isIdenticalLogGrouped"); + Setting logType("sync"); + setFromToml(logType, general, "logType"); + if (logType.get() == "sync") { + s.sync = true; + } else { + s.sync = false; + } + } + + if (og_data.contains("Debug")) { + const toml::value& debug = og_data.at("Debug"); + auto& s = m_log; + + setFromToml(s.enable, debug, "logEnabled"); + setFromToml(s.separate, debug, "isSeparateLogFilesEnabled"); + } + if (og_data.contains("Input")) { const toml::value& input = og_data.at("Input"); auto& s = m_input;