rlottie/example: sort the resource list before displaying.

This commit is contained in:
subhransu mohanty
2019-03-13 19:13:15 +09:00
committed by Subhransu
parent 445cc344cb
commit 416e26cc07
2 changed files with 11 additions and 18 deletions

View File

@@ -18,6 +18,7 @@
#include "evasapp.h"
#include <dirent.h>
#include <algorithm>
static void
_on_resize(Ecore_Evas *ee)
@@ -132,6 +133,9 @@ EvasApp::jsonFiles(const std::string &dirName, bool recurse)
}
closedir(d);
}
std::sort(result.begin(), result.end(), [](auto & a, auto &b){return a < b;});
return result;
}