[Scummvm-cvs-logs] SF.net SVN: scummvm:[50477] scummvm/trunk/engines/mohawk
mthreepwood at users.sourceforge.net
mthreepwood at users.sourceforge.net
Tue Jun 29 04:55:31 CEST 2010
Revision: 50477
http://scummvm.svn.sourceforge.net/scummvm/?rev=50477&view=rev
Author: mthreepwood
Date: 2010-06-29 02:55:31 +0000 (Tue, 29 Jun 2010)
Log Message:
-----------
Fix the load game dialog in Riven DVD's menu, borrowed from Parallaction.
Modified Paths:
--------------
scummvm/trunk/engines/mohawk/riven.cpp
scummvm/trunk/engines/mohawk/riven.h
Modified: scummvm/trunk/engines/mohawk/riven.cpp
===================================================================
--- scummvm/trunk/engines/mohawk/riven.cpp 2010-06-29 01:59:10 UTC (rev 50476)
+++ scummvm/trunk/engines/mohawk/riven.cpp 2010-06-29 02:55:31 UTC (rev 50477)
@@ -76,7 +76,6 @@
delete _extrasFile;
delete _saveLoad;
delete[] _vars;
- delete _loadDialog;
delete _optionsDialog;
delete _rnd;
delete g_atrusJournalRect1;
@@ -100,8 +99,6 @@
_console = new RivenConsole(this);
_saveLoad = new RivenSaveLoad(this, _saveFileMan);
_externalScriptHandler = new RivenExternal(this);
- _loadDialog = new GUI::SaveLoadChooser("Load Game:", "Load");
- _loadDialog->setSaveMode(false);
_optionsDialog = new RivenOptionsDialog(this);
_rnd = new Common::RandomSource();
@@ -600,7 +597,19 @@
}
void MohawkEngine_Riven::runLoadDialog() {
- runDialog(*_loadDialog);
+ GUI::SaveLoadChooser slc("Load Game:", "Load");
+ slc.setSaveMode(false);
+
+ Common::String gameId = ConfMan.get("gameid");
+
+ const EnginePlugin *plugin = 0;
+ EngineMan.findGame(gameId, &plugin);
+
+ int slot = slc.runModal(plugin, ConfMan.getActiveDomainName());
+ if (slot >= 0)
+ loadGameState(slot);
+
+ slc.close();
}
Common::Error MohawkEngine_Riven::loadGameState(int slot) {
Modified: scummvm/trunk/engines/mohawk/riven.h
===================================================================
--- scummvm/trunk/engines/mohawk/riven.h 2010-06-29 01:59:10 UTC (rev 50476)
+++ scummvm/trunk/engines/mohawk/riven.h 2010-06-29 02:55:31 UTC (rev 50477)
@@ -128,7 +128,6 @@
MohawkArchive *_extrasFile; // We need a separate handle for the extra data
RivenConsole *_console;
RivenSaveLoad *_saveLoad;
- GUI::SaveLoadChooser *_loadDialog;
RivenOptionsDialog *_optionsDialog;
// Stack/Card-related functions and variables
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