diff options
author | Eugene Sandulenko | 2007-01-20 21:27:57 +0000 |
---|---|---|
committer | Eugene Sandulenko | 2007-01-20 21:27:57 +0000 |
commit | cd8a5f3a98287fe7366db100c2fb45ff986e2d1b (patch) | |
tree | c3acca9454ff39fc71da8444eb98494683a6261f /engines/touche | |
parent | 47b1321d1520eabcfa4d971bd945f4461eeada49 (diff) | |
download | scummvm-rg350-cd8a5f3a98287fe7366db100c2fb45ff986e2d1b.tar.gz scummvm-rg350-cd8a5f3a98287fe7366db100c2fb45ff986e2d1b.tar.bz2 scummvm-rg350-cd8a5f3a98287fe7366db100c2fb45ff986e2d1b.zip |
First phase of detection-related plugins interface improvements. Now plugins
return StringMap instead of fixed list of parameters. This adds great
flexibility.
Current patch should not alter any functionality, i.e. if there are regressions,
submit a report. Phase 2 will benefit from these changes and will come later.
svn-id: r25134
Diffstat (limited to 'engines/touche')
-rw-r--r-- | engines/touche/plugin.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/touche/plugin.cpp b/engines/touche/plugin.cpp index 168223b6f3..08c2a49bd9 100644 --- a/engines/touche/plugin.cpp +++ b/engines/touche/plugin.cpp @@ -123,7 +123,7 @@ GameDescriptor Engine_TOUCHE_findGameID(const char *gameid) { return GameDescriptor(); } -DetectedGameList Engine_TOUCHE_detectGames(const FSList &fslist) { +GameList Engine_TOUCHE_detectGames(const FSList &fslist) { bool foundFile = false; FSList::const_iterator file; for (file = fslist.begin(); file != fslist.end(); ++file) { @@ -140,7 +140,7 @@ DetectedGameList Engine_TOUCHE_detectGames(const FSList &fslist) { break; } } - DetectedGameList detectedGames; + GameList detectedGames; if (foundFile) { // Currently, the detection code is based on a MD5 checksum. If all known versions // have a different file size for TOUCHE.DAT, we may consider using this to do the @@ -150,7 +150,7 @@ DetectedGameList Engine_TOUCHE_detectGames(const FSList &fslist) { for (int i = 0; i < ARRAYSIZE(toucheGameVersionsTable); ++i) { const GameVersion *gv = &toucheGameVersionsTable[i]; if (md5digest.equalsIgnoreCase(gv->md5digest)) { - DetectedGame dg(toucheGameDescriptor.gameid, gv->description, gv->language, gv->platform); + GameDescriptor dg(toucheGameDescriptor.gameid, gv->description, gv->language, gv->platform); detectedGames.push_back(dg); break; } @@ -172,12 +172,12 @@ PluginError Engine_TOUCHE_create(OSystem *system, Engine **engine) { if (!dir.listDir(fslist, FilesystemNode::kListFilesOnly)) { return kInvalidPathError; } - DetectedGameList game = Engine_TOUCHE_detectGames(fslist); + GameList game = Engine_TOUCHE_detectGames(fslist); if (game.size() != 1) { return kNoGameDataFoundError; } assert(engine); - *engine = new Touche::ToucheEngine(system, game[0].language); + *engine = new Touche::ToucheEngine(system, game[0].language()); return kNoError; } |