pull/37/head
kunfei 5 years ago
parent ae3bcf98ec
commit 61144577b0
  1. 1
      app/src/main/java/io/legado/app/data/dao/BookChapterDao.kt
  2. 7
      app/src/main/java/io/legado/app/ui/main/bookshelf/BooksAdapter.kt

@ -25,7 +25,6 @@ interface BookChapterDao {
@Insert(onConflict = OnConflictStrategy.REPLACE)
fun insert(vararg bookChapter: BookChapter)
@Query("delete from chapters where bookUrl = :bookUrl")
fun delByBook(bookUrl: String)

@ -32,6 +32,13 @@ class BooksAdapter(private val callBack: CallBack) :
&& oldItem.getDisplayCover() == newItem.getDisplayCover()
&& oldItem.latestChapterTitle == newItem.latestChapterTitle
&& oldItem.durChapterTitle == newItem.durChapterTitle
override fun getChangePayload(oldItem: Book, newItem: Book): Any? {
if (oldItem.bookUrl != newItem.bookUrl) {
return null
}
return super.getChangePayload(oldItem, newItem)
}
}
}

Loading…
Cancel
Save