aboutsummaryrefslogtreecommitdiff
path: root/launcher/minecraft/mod/Resource.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'launcher/minecraft/mod/Resource.cpp')
-rw-r--r--launcher/minecraft/mod/Resource.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/launcher/minecraft/mod/Resource.cpp b/launcher/minecraft/mod/Resource.cpp
index a0b8a4bb..e5077260 100644
--- a/launcher/minecraft/mod/Resource.cpp
+++ b/launcher/minecraft/mod/Resource.cpp
@@ -71,6 +71,7 @@ std::pair<int, bool> Resource::compare(const Resource& other, SortType type) con
return { 1, type == SortType::ENABLED };
if (!enabled() && other.enabled())
return { -1, type == SortType::ENABLED };
+ break;
case SortType::NAME: {
QString this_name{ name() };
QString other_name{ other.name() };
@@ -81,12 +82,14 @@ std::pair<int, bool> Resource::compare(const Resource& other, SortType type) con
auto compare_result = QString::compare(this_name, other_name, Qt::CaseInsensitive);
if (compare_result != 0)
return { compare_result, type == SortType::NAME };
+ break;
}
case SortType::DATE:
if (dateTimeChanged() > other.dateTimeChanged())
return { 1, type == SortType::DATE };
if (dateTimeChanged() < other.dateTimeChanged())
return { -1, type == SortType::DATE };
+ break;
}
return { 0, false };