mirror of
https://github.com/mihonapp/mihon.git
synced 2025-10-28 12:57:57 +01:00
Merge f702839932 into 6b2bba4e54
This commit is contained in:
@@ -178,6 +178,7 @@ private fun ColumnScope.SortPage(
|
||||
MR.strings.action_sort_latest_chapter to LibrarySort.Type.LatestChapter,
|
||||
MR.strings.action_sort_chapter_fetch_date to LibrarySort.Type.ChapterFetchDate,
|
||||
MR.strings.action_sort_date_added to LibrarySort.Type.DateAdded,
|
||||
MR.strings.action_sort_download_count to LibrarySort.Type.DownloadCount,
|
||||
).plus(trackerSortOption).map { (titleRes, mode) ->
|
||||
SortItem(
|
||||
label = stringResource(titleRes),
|
||||
|
||||
@@ -300,6 +300,9 @@ class LibraryScreenModel(
|
||||
val item2Score = trackerScores[i2.libraryManga.id] ?: defaultTrackerScoreSortValue
|
||||
item1Score.compareTo(item2Score)
|
||||
}
|
||||
LibrarySort.Type.DownloadCount -> {
|
||||
i1.downloadCount.compareTo(i2.downloadCount)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user