From 89512c0db8a77debf26e7608e87078ac0742875d Mon Sep 17 00:00:00 2001 From: kunfei Date: Wed, 2 Oct 2019 11:08:58 +0800 Subject: [PATCH] up --- .../legado/app/ui/book/source/manage/BookSourceActivity.kt | 5 ++--- .../io/legado/app/ui/rss/source/manage/RssSourceActivity.kt | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt index 81364c11e..258e8b52d 100644 --- a/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/book/source/manage/BookSourceActivity.kt @@ -135,9 +135,8 @@ class BookSourceActivity : VMBaseActivity(R.layout.activity } bookSourceLiveDate?.observe(this, Observer { search_view.queryHint = getString(R.string.search_book_source_num, it.size) - val diffResult = DiffUtil.calculateDiff( - DiffCallBack(adapter.getItems(), it) - ) + val diffResult = DiffUtil + .calculateDiff(DiffCallBack(adapter.getItems(), it)) adapter.setItemsNoNotify(it) diffResult.dispatchUpdatesTo(adapter) }) diff --git a/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt b/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt index 09eb27e39..0a2c2f0bd 100644 --- a/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt +++ b/app/src/main/java/io/legado/app/ui/rss/source/manage/RssSourceActivity.kt @@ -91,9 +91,8 @@ class RssSourceActivity : VMBaseActivity(R.layout.activity_r sourceLiveData?.removeObservers(this) sourceLiveData = App.db.rssSourceDao().liveAll() sourceLiveData?.observe(this, Observer { - val diffResult = DiffUtil.calculateDiff( - DiffCallBack(adapter.getItems(), it) - ) + val diffResult = DiffUtil + .calculateDiff(DiffCallBack(adapter.getItems(), it)) adapter.setItemsNoNotify(it) diffResult.dispatchUpdatesTo(adapter) })