From e3389ff8afd6fd1f542469abeaceb7dd24f12ea7 Mon Sep 17 00:00:00 2001 From: kunfei Date: Thu, 6 Feb 2020 18:12:58 +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 --- .../java/io/legado/app/ui/book/arrange/ArrangeBookActivity.kt | 1 + .../java/io/legado/app/ui/book/arrange/ArrangeBookAdapter.kt | 2 ++ 2 files changed, 3 insertions(+) diff --git a/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookActivity.kt b/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookActivity.kt index 421bce7fd..056b55999 100644 --- a/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookActivity.kt @@ -61,6 +61,7 @@ class ArrangeBookActivity : VMBaseActivity(R.layout.activi booksLiveData = App.db.bookDao().observeAll() booksLiveData?.observe(this, Observer { adapter.setItems(it) + upSelectCount() }) } diff --git a/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookAdapter.kt b/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookAdapter.kt index eefadb9b3..c24011ee4 100644 --- a/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookAdapter.kt +++ b/app/src/main/java/io/legado/app/ui/book/arrange/ArrangeBookAdapter.kt @@ -27,6 +27,7 @@ class ArrangeBookAdapter(context: Context, val callBack: CallBack) : } else { selectedBooks.remove(item.bookUrl) } + callBack.upSelectCount() } onClick { checkbox.isChecked = !checkbox.isChecked @@ -35,6 +36,7 @@ class ArrangeBookAdapter(context: Context, val callBack: CallBack) : } else { selectedBooks.remove(item.bookUrl) } + callBack.upSelectCount() } } }