[Scummvm-git-logs] scummvm master -> 2e20971babc7652fa3e14f79582dcfad452f066b

bgK bastien.bouclet at gmail.com
Sun Mar 29 18:02:42 UTC 2020


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
2e20971bab ENGINES: Register all the extra gui options default values on game start


Commit: 2e20971babc7652fa3e14f79582dcfad452f066b
    https://github.com/scummvm/scummvm/commit/2e20971babc7652fa3e14f79582dcfad452f066b
Author: Bastien Bouclet (bastien.bouclet at gmail.com)
Date: 2020-03-29T20:02:33+02:00

Commit Message:
ENGINES: Register all the extra gui options default values on game start

Fixes #11398. This regressed due to the recent configuration dialog
changes.

Changed paths:
    engines/metaengine.cpp


diff --git a/engines/metaengine.cpp b/engines/metaengine.cpp
index a46faf29e4..4884c8be32 100644
--- a/engines/metaengine.cpp
+++ b/engines/metaengine.cpp
@@ -338,8 +338,12 @@ SaveStateList MetaEngine::listSaves(const char *target, bool saveMode) const {
 	return saveList;
 }
 
-void MetaEngine::registerDefaultSettings(const Common::String &target) const {
-	const ExtraGuiOptions engineOptions = getExtraGuiOptions(target);
+void MetaEngine::registerDefaultSettings(const Common::String &) const {
+	// Note that as we don't pass the target to getExtraGuiOptions
+	//  we get all the options, even those not relevant for the current
+	//  game. This is necessary because some engines unconditionally
+	//  access the configuration.
+	const ExtraGuiOptions engineOptions = getExtraGuiOptions("");
 	for (uint i = 0; i < engineOptions.size(); i++) {
 		ConfMan.registerDefault(engineOptions[i].configOption, engineOptions[i].defaultState);
 	}




More information about the Scummvm-git-logs mailing list