aboutsummaryrefslogtreecommitdiff
path: root/engines/neverhood
diff options
context:
space:
mode:
authorJohannes Schickel2016-02-25 19:55:14 +0100
committerJohannes Schickel2016-02-25 21:39:45 +0100
commit37c1a06df90e8b59c54fd345b3a76ff1399f8644 (patch)
tree4a192e4b4480c944f29074b5b8660ad8063ce165 /engines/neverhood
parentbed73e6cfad2b16f0813c898778ab990a2157d69 (diff)
downloadscummvm-rg350-37c1a06df90e8b59c54fd345b3a76ff1399f8644.tar.gz
scummvm-rg350-37c1a06df90e8b59c54fd345b3a76ff1399f8644.tar.bz2
scummvm-rg350-37c1a06df90e8b59c54fd345b3a76ff1399f8644.zip
NEVERHOOD: Let listSaves return list sorted on slot numbers.
Diffstat (limited to 'engines/neverhood')
-rw-r--r--engines/neverhood/detection.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/neverhood/detection.cpp b/engines/neverhood/detection.cpp
index 4d545e136c..c663d5d3a4 100644
--- a/engines/neverhood/detection.cpp
+++ b/engines/neverhood/detection.cpp
@@ -245,7 +245,6 @@ SaveStateList NeverhoodMetaEngine::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;
for (Common::StringArray::const_iterator file = filenames.begin(); file != filenames.end(); file++) {
@@ -262,6 +261,8 @@ SaveStateList NeverhoodMetaEngine::listSaves(const char *target) const {
}
}
+ // Sort saves based on slot number.
+ Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator());
return saveList;
}