From 28f5a6986ffaa76bc100bfed78d26b23ce3374d2 Mon Sep 17 00:00:00 2001 From: Jays2Kings Date: Fri, 26 Mar 2021 02:20:30 -0400 Subject: [PATCH] More fixes to category hopper --- .../eu/kanade/tachiyomi/ui/library/LibraryController.kt | 9 +++++---- app/src/main/res/layout/library_list_controller.xml | 3 +-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt index 5d37da1f3d..ef6eeee438 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt @@ -615,11 +615,12 @@ class LibraryController( } category_hopper_frame.y = -category_hopper_frame.height + (listOfYs.minOrNull() ?: filter_bottom_sheet.y) + - hopperOffset + hopperOffset + + recycler.translationY if (view.height - insetBottom < category_hopper_frame.y) { - jumper_category_text.translationY = -(category_hopper_frame.y - (view.height - insetBottom)) + jumper_category_text.translationY = -(category_hopper_frame.y - (view.height - insetBottom)) + recycler.translationY } else { - jumper_category_text.translationY = 0f + jumper_category_text.translationY = recycler.translationY } } @@ -913,9 +914,9 @@ class LibraryController( recycler.animate().translationY(translateY).apply { setUpdateListener { activity?.appbar?.y = 0f + updateHopperY() } }.start() - category_hopper_frame.animate().translationY(translateY).start() recycler_shadow.animate().translationY(translateY - 8.dpToPx).start() recycler_cover.animate().translationY(translateY).start() recycler_cover.animate().alpha(if (show) 0.75f else 0f).start() diff --git a/app/src/main/res/layout/library_list_controller.xml b/app/src/main/res/layout/library_list_controller.xml index e4d7413fcd..122d82facb 100644 --- a/app/src/main/res/layout/library_list_controller.xml +++ b/app/src/main/res/layout/library_list_controller.xml @@ -116,8 +116,7 @@ android:id="@+id/category_hopper_frame" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_gravity="top|center" - android:translationZ="50dp"> + android:layout_gravity="top|center">