Allow canceling a single migration job but keeping the manga
This commit is contained in:
parent
29d786d8db
commit
7a44fab5e7
@ -88,6 +88,14 @@ class MigrationProcessAdapter(
|
|||||||
|
|
||||||
fun removeManga(position: Int) {
|
fun removeManga(position: Int) {
|
||||||
val item = getItem(position) ?: return
|
val item = getItem(position) ?: return
|
||||||
|
if (items.size == 1) {
|
||||||
|
item.manga.migrationStatus = MigrationStatus.MANGA_NOT_FOUND
|
||||||
|
item.manga.migrationJob.cancel()
|
||||||
|
item.manga.searchResult.initialize(null)
|
||||||
|
sourceFinished()
|
||||||
|
notifyDataSetChanged()
|
||||||
|
return
|
||||||
|
}
|
||||||
menuItemListener.removeManga(item)
|
menuItemListener.removeManga(item)
|
||||||
item.manga.migrationJob.cancel()
|
item.manga.migrationJob.cancel()
|
||||||
removeItem(position)
|
removeItem(position)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user