From 5d90ba8aa048f45bde662dfe4249f4d9fb45bb83 Mon Sep 17 00:00:00 2001 From: arkon Date: Sun, 8 Jan 2023 10:43:01 -0500 Subject: [PATCH] Only show library continue reading button if there's unread chapters Closes #8865 --- .../presentation/library/components/LibraryComfortableGrid.kt | 2 +- .../presentation/library/components/LibraryCompactGrid.kt | 2 +- .../eu/kanade/presentation/library/components/LibraryList.kt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/eu/kanade/presentation/library/components/LibraryComfortableGrid.kt b/app/src/main/java/eu/kanade/presentation/library/components/LibraryComfortableGrid.kt index ee3950146..34724a06d 100644 --- a/app/src/main/java/eu/kanade/presentation/library/components/LibraryComfortableGrid.kt +++ b/app/src/main/java/eu/kanade/presentation/library/components/LibraryComfortableGrid.kt @@ -57,7 +57,7 @@ fun LibraryComfortableGrid( }, onLongClick = { onLongClick(libraryItem.libraryManga) }, onClick = { onClick(libraryItem.libraryManga) }, - onClickContinueReading = if (onClickContinueReading != null) { + onClickContinueReading = if (onClickContinueReading != null && libraryItem.unreadCount > 0) { { onClickContinueReading(libraryItem.libraryManga) } } else { null diff --git a/app/src/main/java/eu/kanade/presentation/library/components/LibraryCompactGrid.kt b/app/src/main/java/eu/kanade/presentation/library/components/LibraryCompactGrid.kt index de3309325..12c0ac809 100644 --- a/app/src/main/java/eu/kanade/presentation/library/components/LibraryCompactGrid.kt +++ b/app/src/main/java/eu/kanade/presentation/library/components/LibraryCompactGrid.kt @@ -58,7 +58,7 @@ fun LibraryCompactGrid( }, onLongClick = { onLongClick(libraryItem.libraryManga) }, onClick = { onClick(libraryItem.libraryManga) }, - onClickContinueReading = if (onClickContinueReading != null) { + onClickContinueReading = if (onClickContinueReading != null && libraryItem.unreadCount > 0) { { onClickContinueReading(libraryItem.libraryManga) } } else { null diff --git a/app/src/main/java/eu/kanade/presentation/library/components/LibraryList.kt b/app/src/main/java/eu/kanade/presentation/library/components/LibraryList.kt index 4be5ebaa5..51d973e41 100644 --- a/app/src/main/java/eu/kanade/presentation/library/components/LibraryList.kt +++ b/app/src/main/java/eu/kanade/presentation/library/components/LibraryList.kt @@ -65,7 +65,7 @@ fun LibraryList( }, onLongClick = { onLongClick(libraryItem.libraryManga) }, onClick = { onClick(libraryItem.libraryManga) }, - onClickContinueReading = if (onClickContinueReading != null) { + onClickContinueReading = if (onClickContinueReading != null && libraryItem.unreadCount > 0) { { onClickContinueReading(libraryItem.libraryManga) } } else { null