From d38a22011e53570629620166653978d32e35f5e8 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Thu, 25 Feb 2016 19:55:15 +0100 Subject: ZVISION: Let listSaves return list sorted on slot numbers. --- engines/zvision/detection.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'engines') 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; } -- cgit v1.2.3