lib: Make sorts of projects and account mangers case-insensitive

svn path=/trunk/boinc/; revision=23221
This commit is contained in:
Charlie Fenton 2011-03-11 12:10:12 +00:00
parent a67dfe5d65
commit a561d08e42
1 changed files with 8 additions and 0 deletions

View File

@ -175,12 +175,20 @@ ALL_PROJECTS_LIST::~ALL_PROJECTS_LIST() {
bool compare_project_list_entry(const PROJECT_LIST_ENTRY* a, const PROJECT_LIST_ENTRY* b)
{
#ifdef _WIN32
return _stricmp(a->name.c_str(), b->name.c_str()) < 0;
#else
return strcasecmp(a->name.c_str(), b->name.c_str()) < 0;
#endif
}
bool compare_am_list_entry(const AM_LIST_ENTRY* a, const AM_LIST_ENTRY* b)
{
#ifdef _WIN32
return _stricmp(a->name.c_str(), b->name.c_str()) < 0;
#else
return strcasecmp(a->name.c_str(), b->name.c_str()) < 0;
#endif
}
void ALL_PROJECTS_LIST::shuffle() {