aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorJohannes Schickel2016-02-25 19:55:15 +0100
committerJohannes Schickel2016-02-25 21:39:45 +0100
commitd38a22011e53570629620166653978d32e35f5e8 (patch)
treecc2cab448dbd94510ea231b75f211b3b0a92e878 /engines
parent2b53a26bb4f609261c0a45a23c7fc65be6063afe (diff)
downloadscummvm-rg350-d38a22011e53570629620166653978d32e35f5e8.tar.gz
scummvm-rg350-d38a22011e53570629620166653978d32e35f5e8.tar.bz2
scummvm-rg350-d38a22011e53570629620166653978d32e35f5e8.zip
ZVISION: Let listSaves return list sorted on slot numbers.
Diffstat (limited to 'engines')
-rw-r--r--engines/zvision/detection.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/zvision/detection.cpp b/engines/zvision/detection.cpp
index 5fdf17cd2b..27ccbeb9a6 100644
--- a/engines/zvision/detection.cpp
+++ b/engines/zvision/detection.cpp
@@ -132,7 +132,6 @@ SaveStateList ZVisionMetaEngine::listSaves(const char *target) const {
Common::StringArray filenames;
filenames = saveFileMan->listSavefiles(pattern.c_str());
- Common::sort(filenames.begin(), filenames.end()); // Sort (hopefully ensuring we are sorted numerically..)*/
SaveStateList saveList;
// We only use readSaveGameHeader() here, which doesn't need an engine callback
@@ -155,6 +154,8 @@ SaveStateList ZVisionMetaEngine::listSaves(const char *target) const {
delete zvisionSaveMan;
+ // Sort saves based on slot number.
+ Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator());
return saveList;
}