Skip to content

Commit

Permalink
Nicer sorting of ellipsoid defs
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Mar 27, 2019
1 parent edd84e9 commit 6e57bfa
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/core/qgsellipsoidutils.cpp
Expand Up @@ -263,6 +263,12 @@ QList<QgsEllipsoidUtils::EllipsoidDefinition> QgsEllipsoidUtils::definitions()

#endif

QCollator collator;
collator.setCaseSensitivity( Qt::CaseInsensitive );
std::sort( defs.begin(), defs.end(), [&collator]( const EllipsoidDefinition & a, const EllipsoidDefinition & b )
{
return collator.compare( a.acronym, b.acronym ) < 0;
} );
sDefinitionCache = defs;
sDefinitionCacheLock.unlock();

Expand Down

0 comments on commit 6e57bfa

Please sign in to comment.