diff options
author | Johannes Schickel | 2016-02-25 19:55:14 +0100 |
---|---|---|
committer | Johannes Schickel | 2016-02-25 21:39:45 +0100 |
commit | bed73e6cfad2b16f0813c898778ab990a2157d69 (patch) | |
tree | b10d67741c3e15b6788ce2658a0aaa92a7f40a6e /engines/mads | |
parent | 4892a83cf625cfb09f70565c0332d9e007a3858b (diff) | |
download | scummvm-rg350-bed73e6cfad2b16f0813c898778ab990a2157d69.tar.gz scummvm-rg350-bed73e6cfad2b16f0813c898778ab990a2157d69.tar.bz2 scummvm-rg350-bed73e6cfad2b16f0813c898778ab990a2157d69.zip |
MADS: Let listSaves return list sorted on slot numbers.
Diffstat (limited to 'engines/mads')
-rw-r--r-- | engines/mads/detection.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/mads/detection.cpp b/engines/mads/detection.cpp index 0357bd4bcc..b3ba60b6d0 100644 --- a/engines/mads/detection.cpp +++ b/engines/mads/detection.cpp @@ -192,7 +192,6 @@ SaveStateList MADSMetaEngine::listSaves(const char *target) const { MADS::MADSSavegameHeader header; filenames = saveFileMan->listSavefiles(pattern); - sort(filenames.begin(), filenames.end()); // Sort to get the files in numerical order SaveStateList saveList; for (Common::StringArray::const_iterator file = filenames.begin(); file != filenames.end(); ++file) { @@ -213,6 +212,8 @@ SaveStateList MADSMetaEngine::listSaves(const char *target) const { } } + // Sort saves based on slot number. + Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator()); return saveList; } |