mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-24 21:21:05 +00:00
SCUMM: Let listSaves return list sorted on slot numbers.
This commit is contained in:
parent
cea96e4a39
commit
d1cf867fc4
@ -1271,7 +1271,6 @@ SaveStateList ScummMetaEngine::listSaves(const char *target) const {
|
||||
pattern += ".s##";
|
||||
|
||||
filenames = saveFileMan->listSavefiles(pattern);
|
||||
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) {
|
||||
@ -1288,6 +1287,8 @@ SaveStateList ScummMetaEngine::listSaves(const char *target) const {
|
||||
}
|
||||
}
|
||||
|
||||
// Sort saves based on slot number.
|
||||
Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator());
|
||||
return saveList;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user