mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2025-01-11 16:59:09 +01:00
Small UI tweaks
Download 3 dots hidden when theres a single chapter downloading Recents now shows the chapter as the title, manga as subtitle Library List view: moved start reading button outside of the manga Reenabled freeform covers Also never commited the fast scroll the gradle, oops
This commit is contained in:
parent
73373cab56
commit
4e33b93c08
@ -195,6 +195,7 @@ dependencies {
|
|||||||
implementation("me.zhanghai.android.systemuihelper:library:1.0.0")
|
implementation("me.zhanghai.android.systemuihelper:library:1.0.0")
|
||||||
implementation("com.nightlynexus.viewstatepageradapter:viewstatepageradapter:1.1.0")
|
implementation("com.nightlynexus.viewstatepageradapter:viewstatepageradapter:1.1.0")
|
||||||
implementation("com.github.mthli:Slice:v1.2")
|
implementation("com.github.mthli:Slice:v1.2")
|
||||||
|
implementation("com.reddit:indicator-fast-scroll:1.2.1")
|
||||||
|
|
||||||
implementation("com.github.kizitonwose:AndroidTagGroup:1.6.0")
|
implementation("com.github.kizitonwose:AndroidTagGroup:1.6.0")
|
||||||
implementation("com.github.chrisbanes:PhotoView:2.3.0")
|
implementation("com.github.chrisbanes:PhotoView:2.3.0")
|
||||||
|
@ -7,6 +7,7 @@ import eu.kanade.tachiyomi.data.download.model.Download
|
|||||||
import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder
|
import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder
|
||||||
import eu.kanade.tachiyomi.util.system.getResourceColor
|
import eu.kanade.tachiyomi.util.system.getResourceColor
|
||||||
import eu.kanade.tachiyomi.util.view.setVectorCompat
|
import eu.kanade.tachiyomi.util.view.setVectorCompat
|
||||||
|
import eu.kanade.tachiyomi.util.view.visibleIf
|
||||||
import kotlinx.android.synthetic.main.download_item.*
|
import kotlinx.android.synthetic.main.download_item.*
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -51,6 +52,7 @@ class DownloadHolder(private val view: View, val adapter: DownloadAdapter) :
|
|||||||
notifyDownloadedPages()
|
notifyDownloadedPages()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
migration_menu.visibleIf(adapterPosition != 0 || adapterPosition != adapter.itemCount - 1)
|
||||||
migration_menu.setVectorCompat(
|
migration_menu.setVectorCompat(
|
||||||
R.drawable.ic_more_vert_black_24dp, view.context
|
R.drawable.ic_more_vert_black_24dp, view.context
|
||||||
.getResourceColor(R.attr.icon_color))
|
.getResourceColor(R.attr.icon_color))
|
||||||
|
@ -47,7 +47,7 @@ class LibraryItem(
|
|||||||
val parent = adapter.recyclerView
|
val parent = adapter.recyclerView
|
||||||
return if (parent is AutofitRecyclerView) {
|
return if (parent is AutofitRecyclerView) {
|
||||||
val libraryLayout = libraryLayout.getOrDefault()
|
val libraryLayout = libraryLayout.getOrDefault()
|
||||||
val isFixedSize = true // fixedSize.getOrDefault()
|
val isFixedSize = fixedSize.getOrDefault()
|
||||||
if (libraryLayout == 0 || manga.isBlank()) {
|
if (libraryLayout == 0 || manga.isBlank()) {
|
||||||
LibraryListHolder(view, adapter as LibraryCategoryAdapter)
|
LibraryListHolder(view, adapter as LibraryCategoryAdapter)
|
||||||
} else {
|
} else {
|
||||||
|
@ -37,9 +37,9 @@ class RecentMangaHolder(
|
|||||||
|
|
||||||
fun bind(item: RecentMangaItem) {
|
fun bind(item: RecentMangaItem) {
|
||||||
download_button.visibleIf(item.mch.manga.source != LocalSource.ID)
|
download_button.visibleIf(item.mch.manga.source != LocalSource.ID)
|
||||||
title.text = item.mch.manga.title
|
subtitle.text = item.mch.manga.title
|
||||||
val isSearch = adapter.delegate.isSearching()
|
val isSearch = adapter.delegate.isSearching()
|
||||||
subtitle.text = item.chapter.name
|
title.text = item.chapter.name
|
||||||
val notValidNum = item.mch.chapter.chapter_number <= 0
|
val notValidNum = item.mch.chapter.chapter_number <= 0
|
||||||
body.text = when {
|
body.text = when {
|
||||||
item.mch.chapter.id == null -> body.context.getString(
|
item.mch.chapter.id == null -> body.context.getString(
|
||||||
|
@ -37,29 +37,6 @@
|
|||||||
tools:ignore="ContentDescription"
|
tools:ignore="ContentDescription"
|
||||||
tools:src="@mipmap/ic_launcher" />
|
tools:src="@mipmap/ic_launcher" />
|
||||||
|
|
||||||
<FrameLayout
|
|
||||||
android:id="@+id/play_layout"
|
|
||||||
android:layout_width="55dp"
|
|
||||||
android:layout_height="match_parent"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:clickable="true"
|
|
||||||
android:focusable="true"
|
|
||||||
android:visibility="gone"
|
|
||||||
tools:visibility="visible">
|
|
||||||
|
|
||||||
<ImageView
|
|
||||||
android:id="@+id/play_button"
|
|
||||||
android:layout_width="30dp"
|
|
||||||
android:layout_height="30dp"
|
|
||||||
android:layout_gravity="center"
|
|
||||||
android:background="@drawable/round_play_background"
|
|
||||||
android:contentDescription="@string/start_reading"
|
|
||||||
android:padding="6dp"
|
|
||||||
android:src="@drawable/ic_start_reading_white_24dp"
|
|
||||||
android:tint="@android:color/white" />
|
|
||||||
|
|
||||||
</FrameLayout>
|
|
||||||
|
|
||||||
<ProgressBar
|
<ProgressBar
|
||||||
android:id="@+id/progress"
|
android:id="@+id/progress"
|
||||||
style="?android:attr/progressBarStyleSmall"
|
style="?android:attr/progressBarStyleSmall"
|
||||||
@ -87,7 +64,7 @@
|
|||||||
android:textColor="?android:attr/textColorPrimary"
|
android:textColor="?android:attr/textColorPrimary"
|
||||||
android:textSize="16sp"
|
android:textSize="16sp"
|
||||||
app:layout_constrainedWidth="true"
|
app:layout_constrainedWidth="true"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/badge_view"
|
app:layout_constraintEnd_toStartOf="@+id/play_layout"
|
||||||
app:layout_constraintHorizontal_bias="0.0"
|
app:layout_constraintHorizontal_bias="0.0"
|
||||||
app:layout_constraintStart_toEndOf="@+id/card"
|
app:layout_constraintStart_toEndOf="@+id/card"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
@ -106,13 +83,41 @@
|
|||||||
android:textColor="?android:attr/textColorSecondary"
|
android:textColor="?android:attr/textColorSecondary"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
app:layout_constrainedWidth="true"
|
app:layout_constrainedWidth="true"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/badge_view"
|
app:layout_constraintEnd_toStartOf="@+id/play_layout"
|
||||||
app:layout_constraintHorizontal_bias="0.0"
|
app:layout_constraintHorizontal_bias="0.0"
|
||||||
app:layout_constraintStart_toStartOf="@+id/title"
|
app:layout_constraintStart_toStartOf="@+id/title"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/title"
|
app:layout_constraintTop_toBottomOf="@+id/title"
|
||||||
app:layout_constraintVertical_bias="0.0"
|
app:layout_constraintVertical_bias="0.0"
|
||||||
tools:text="Manga artist" />
|
tools:text="Manga artist" />
|
||||||
|
|
||||||
|
<FrameLayout
|
||||||
|
android:id="@+id/play_layout"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="55dp"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:layout_marginBottom="6dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
app:layout_constraintEnd_toStartOf="@id/badge_view"
|
||||||
|
app:layout_constraintTop_toTopOf="@id/badge_view"
|
||||||
|
app:layout_constraintBottom_toBottomOf="@id/badge_view"
|
||||||
|
android:layout_marginEnd="8dp"
|
||||||
|
android:clickable="true"
|
||||||
|
android:focusable="true"
|
||||||
|
android:visibility="gone"
|
||||||
|
tools:visibility="visible">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/play_button"
|
||||||
|
android:layout_width="30dp"
|
||||||
|
android:layout_height="30dp"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:background="@drawable/round_play_background"
|
||||||
|
android:contentDescription="@string/start_reading"
|
||||||
|
android:padding="6dp"
|
||||||
|
android:src="@drawable/ic_start_reading_white_24dp"
|
||||||
|
android:tint="@android:color/white" />
|
||||||
|
|
||||||
|
</FrameLayout>
|
||||||
|
|
||||||
<include layout="@layout/unread_download_badge"
|
<include layout="@layout/unread_download_badge"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
|
@ -92,7 +92,6 @@
|
|||||||
<com.google.android.material.checkbox.MaterialCheckBox
|
<com.google.android.material.checkbox.MaterialCheckBox
|
||||||
android:id="@+id/uniform_grid"
|
android:id="@+id/uniform_grid"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="12dp"
|
android:layout_marginStart="12dp"
|
||||||
android:layout_marginEnd="12dp"
|
android:layout_marginEnd="12dp"
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
android:layout_height="24dp"
|
android:layout_height="24dp"
|
||||||
android:tint="@color/md_white_1000"
|
android:tint="@color/md_white_1000"
|
||||||
android:layout_gravity="end|center"
|
android:layout_gravity="end|center"
|
||||||
|
android:contentDescription="@string/action_cancel"
|
||||||
android:layout_marginEnd="21dp"
|
android:layout_marginEnd="21dp"
|
||||||
android:src="@drawable/ic_close_white_24dp" />
|
android:src="@drawable/ic_close_white_24dp" />
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
@ -33,6 +34,7 @@
|
|||||||
android:id="@+id/close_left"
|
android:id="@+id/close_left"
|
||||||
android:layout_width="24dp"
|
android:layout_width="24dp"
|
||||||
android:layout_height="24dp"
|
android:layout_height="24dp"
|
||||||
|
android:contentDescription="@string/action_cancel"
|
||||||
android:layout_gravity="start|center"
|
android:layout_gravity="start|center"
|
||||||
android:layout_marginStart="21dp"
|
android:layout_marginStart="21dp"
|
||||||
android:tint="@color/md_white_1000"
|
android:tint="@color/md_white_1000"
|
||||||
@ -57,7 +59,7 @@
|
|||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
app:srcCompat="@drawable/ic_drag_handle_black_24dp" />
|
app:srcCompat="@drawable/ic_reorder_grey_24dp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/manga_full_title"
|
android:id="@+id/manga_full_title"
|
||||||
@ -83,6 +85,7 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textAppearance="@style/TextAppearance.Regular.Caption"
|
android:textAppearance="@style/TextAppearance.Regular.Caption"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
||||||
|
android:layout_marginEnd="16dp"
|
||||||
app:layout_constraintStart_toStartOf="@+id/manga_full_title"
|
app:layout_constraintStart_toStartOf="@+id/manga_full_title"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/manga_full_title"
|
app:layout_constraintTop_toBottomOf="@+id/manga_full_title"
|
||||||
tools:text="Chapter Title" />
|
tools:text="Chapter Title" />
|
||||||
@ -96,6 +99,7 @@
|
|||||||
app:layout_constraintBottom_toBottomOf="parent"
|
app:layout_constraintBottom_toBottomOf="parent"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
||||||
app:layout_constraintStart_toEndOf="@+id/reorder"
|
app:layout_constraintStart_toEndOf="@+id/reorder"
|
||||||
|
android:layout_marginEnd="16dp"
|
||||||
app:layout_constraintTop_toBottomOf="@+id/chapter_title" />
|
app:layout_constraintTop_toBottomOf="@+id/chapter_title" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
@ -106,6 +110,7 @@
|
|||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textAppearance="@style/TextAppearance.Regular.Caption.Hint"
|
android:textAppearance="@style/TextAppearance.Regular.Caption.Hint"
|
||||||
app:layout_constraintBottom_toBottomOf="@+id/manga_full_title"
|
app:layout_constraintBottom_toBottomOf="@+id/manga_full_title"
|
||||||
|
android:layout_marginEnd="16dp"
|
||||||
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
app:layout_constraintEnd_toStartOf="@+id/migration_menu"
|
||||||
app:layout_constraintTop_toTopOf="@+id/manga_full_title"
|
app:layout_constraintTop_toTopOf="@+id/manga_full_title"
|
||||||
tools:text="(0/10)" />
|
tools:text="(0/10)" />
|
||||||
|
Loading…
x
Reference in New Issue
Block a user