From 5f776877c4a34897ae87c198a08d64a529875046 Mon Sep 17 00:00:00 2001 From: 821938089 <821938089@qq.com> Date: Sat, 13 Aug 2022 13:47:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../app/ui/book/source/manage/GroupManageDialog.kt | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/book/source/manage/GroupManageDialog.kt b/app/src/main/java/io/legado/app/ui/book/source/manage/GroupManageDialog.kt index de77fb446..3b3534caa 100644 --- a/app/src/main/java/io/legado/app/ui/book/source/manage/GroupManageDialog.kt +++ b/app/src/main/java/io/legado/app/ui/book/source/manage/GroupManageDialog.kt @@ -22,10 +22,7 @@ import io.legado.app.lib.dialogs.alert import io.legado.app.lib.theme.backgroundColor import io.legado.app.lib.theme.primaryColor import io.legado.app.ui.widget.recycler.VerticalDivider -import io.legado.app.utils.applyTint -import io.legado.app.utils.requestInputMethod -import io.legado.app.utils.setLayout -import io.legado.app.utils.splitNotBlank +import io.legado.app.utils.* import io.legado.app.utils.viewbindingdelegate.viewBinding import kotlinx.coroutines.launch @@ -62,7 +59,11 @@ class GroupManageDialog : BaseDialogFragment(R.layout.dialog_recycler_view), it.map { group -> groups.addAll(group.splitNotBlank(AppPattern.splitGroupRegex)) } - adapter.setItems(groups.toList()) + adapter.setItems( + groups.sortedWith { o1, o2 -> + o1.cnCompare(o2) + } + ) } } }