From 7b96d74d3b197c23324c5a364809a91ea6800e4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Thu, 16 Jan 2014 23:06:07 +0100 Subject: Sort forge versions right. Do not spam the multimc log with mc server status stuff. --- logic/lists/ForgeVersionList.cpp | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'logic/lists/ForgeVersionList.cpp') diff --git a/logic/lists/ForgeVersionList.cpp b/logic/lists/ForgeVersionList.cpp index 56eca744..38e033fa 100644 --- a/logic/lists/ForgeVersionList.cpp +++ b/logic/lists/ForgeVersionList.cpp @@ -404,12 +404,8 @@ void ForgeListLoadTask::listDownloaded() { return; } - - qSort(list.begin(), list.end(), [](const BaseVersionPtr & p1, const BaseVersionPtr & p2) - { - // TODO better comparison (takes major/minor/build number into account) - return p1->name() > p2->name(); - }); + std::sort(list.begin(), list.end(), [](const BaseVersionPtr & l, const BaseVersionPtr & r) + { return (*l > *r); }); m_list->updateListData(list); -- cgit v1.2.3