diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/MaterialFastScroll.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/MaterialFastScroll.kt
index a01ed62b96..fee9c6209f 100644
--- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/MaterialFastScroll.kt
+++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/MaterialFastScroll.kt
@@ -14,6 +14,8 @@ class MaterialFastScroll @JvmOverloads constructor(context: Context, attrs: Attr
setViewsToUse(
R.layout.material_fastscroll, R.id.fast_scroller_bubble, R.id.fast_scroller_handle
)
+ autoHideEnabled = true
+ ignoreTouchesOutsideHandle = true
}
override fun onTouchEvent(event: MotionEvent): Boolean {
@@ -23,7 +25,9 @@ class MaterialFastScroll @JvmOverloads constructor(context: Context, attrs: Attr
override fun setBubbleAndHandlePosition(y: Float) {
super.setBubbleAndHandlePosition(y)
- bubble.y = handle.y - bubble.height / 2f + handle.height / 2f
- bubble.translationX = (-45f).dpToPxEnd
+ if (bubbleEnabled) {
+ bubble.y = handle.y - bubble.height / 2f + handle.height / 2f
+ bubble.translationX = (-45f).dpToPxEnd
+ }
}
}
diff --git a/app/src/main/res/layout/library_list_controller.xml b/app/src/main/res/layout/library_list_controller.xml
index f54a647cc0..e926e7c88b 100644
--- a/app/src/main/res/layout/library_list_controller.xml
+++ b/app/src/main/res/layout/library_list_controller.xml
@@ -54,11 +54,8 @@
+ android:layout_height="match_parent"
+ app:fastScrollerBubbleEnabled="true" />
+ android:gravity="center"
+ app:layout_anchor="@id/category_hopper_frame"
+ app:layout_anchorGravity="start|center"
+ tools:text="Category and a long one"
+ tools:alpha="1" />
@@ -45,9 +45,9 @@
android:paddingTop="8dp"
android:paddingEnd="0dp"
android:paddingBottom="8dp"
- app:layout_constrainedHeight="true"
android:textColor="?android:attr/textColorPrimary"
app:iconColor="?android:attr/textColorPrimary"
+ app:layout_constrainedHeight="true"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent"
@@ -55,17 +55,13 @@
+ tools:text="Volume 12"
+ tools:alpha="1" />
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index d05f74bbd4..6f3ddd7fea 100644
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -172,6 +172,19 @@
- @drawable/list_item_selector
+
+