From cf685fbc6c6d3c91f0ff741567aec1efbcd35e9c Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Thu, 25 Feb 2016 19:14:51 +0100 Subject: ACCESS: Let listSaves return list sorted on slot numbers. --- engines/access/detection.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/engines/access/detection.cpp b/engines/access/detection.cpp index 7494c9c047..2cd7e50f0f 100644 --- a/engines/access/detection.cpp +++ b/engines/access/detection.cpp @@ -146,7 +146,6 @@ SaveStateList AccessMetaEngine::listSaves(const char *target) const { Access::AccessSavegameHeader 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) { @@ -167,6 +166,8 @@ SaveStateList AccessMetaEngine::listSaves(const char *target) const { } } + // Sort saves based on slot number. + Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator()); return saveList; } -- cgit v1.2.3