[Scummvm-cvs-logs] SF.net SVN: scummvm:[50706] scummvm/trunk
lordhoto at users.sourceforge.net
lordhoto at users.sourceforge.net
Mon Jul 5 22:10:56 CEST 2010
Revision: 50706
http://scummvm.svn.sourceforge.net/scummvm/?rev=50706&view=rev
Author: lordhoto
Date: 2010-07-05 20:10:56 +0000 (Mon, 05 Jul 2010)
Log Message:
-----------
Fix update of GUI options, which only differ in the language setting.
Modified Paths:
--------------
scummvm/trunk/common/util.cpp
scummvm/trunk/common/util.h
scummvm/trunk/engines/advancedDetector.cpp
scummvm/trunk/engines/scumm/detection.cpp
Modified: scummvm/trunk/common/util.cpp
===================================================================
--- scummvm/trunk/common/util.cpp 2010-07-05 20:10:28 UTC (rev 50705)
+++ scummvm/trunk/common/util.cpp 2010-07-05 20:10:56 UTC (rev 50706)
@@ -365,12 +365,15 @@
return res;
}
-void updateGameGUIOptions(const uint32 options) {
+void updateGameGUIOptions(const uint32 options, const String &langOption) {
+ const String newOptionString = getGameGUIOptionsDescription(options) + " " + langOption;
+
if ((options && !ConfMan.hasKey("guioptions")) ||
- (ConfMan.hasKey("guioptions") && options != parseGameGUIOptions(ConfMan.get("guioptions")))) {
- ConfMan.set("guioptions", getGameGUIOptionsDescription(options));
+ (ConfMan.hasKey("guioptions") && ConfMan.get("guioptions") != newOptionString)) {
+ ConfMan.set("guioptions", newOptionString);
ConfMan.flushToDisk();
}
}
-} // End of namespace Common
+} // End of namespace Common
+
Modified: scummvm/trunk/common/util.h
===================================================================
--- scummvm/trunk/common/util.h 2010-07-05 20:10:28 UTC (rev 50705)
+++ scummvm/trunk/common/util.h 2010-07-05 20:10:56 UTC (rev 50706)
@@ -240,7 +240,7 @@
* domain, when they differ to the ones passed as
* parameter.
*/
-void updateGameGUIOptions(const uint32 options);
+void updateGameGUIOptions(const uint32 options, const String &langOption);
} // End of namespace Common
Modified: scummvm/trunk/engines/advancedDetector.cpp
===================================================================
--- scummvm/trunk/engines/advancedDetector.cpp 2010-07-05 20:10:28 UTC (rev 50705)
+++ scummvm/trunk/engines/advancedDetector.cpp 2010-07-05 20:10:56 UTC (rev 50706)
@@ -306,7 +306,7 @@
// If the GUI options were updated, we catch this here and update them in the users config
// file transparently.
- Common::updateGameGUIOptions(agdDesc->guioptions | params.guioptions);
+ Common::updateGameGUIOptions(agdDesc->guioptions | params.guioptions, getGameGUIOptionsDescriptionLanguage(agdDesc->language));
debug(2, "Running %s", toGameDescriptor(*agdDesc, params.list).description().c_str());
if (!createInstance(syst, engine, agdDesc))
Modified: scummvm/trunk/engines/scumm/detection.cpp
===================================================================
--- scummvm/trunk/engines/scumm/detection.cpp 2010-07-05 20:10:28 UTC (rev 50705)
+++ scummvm/trunk/engines/scumm/detection.cpp 2010-07-05 20:10:56 UTC (rev 50706)
@@ -1024,7 +1024,7 @@
// If the GUI options were updated, we catch this here and update them in the users config
// file transparently.
- Common::updateGameGUIOptions(res.game.guioptions);
+ Common::updateGameGUIOptions(res.game.guioptions, getGameGUIOptionsDescriptionLanguage(res.language));
// Finally, we have massaged the GameDescriptor to our satisfaction, and can
// instantiate the appropriate game engine. Hooray!
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list