Library and Light mode improvements.

This commit is contained in:
no-commit 2023-02-02 01:15:24 +01:00
parent b0921161a3
commit 9988753432
5 changed files with 9 additions and 5 deletions

View File

@ -333,8 +333,10 @@ class LibraryFragment : Fragment() {
handler.postDelayed(stopLoading, 300)
savedInstanceState?.getInt(VIEWPAGER_ITEM_KEY)?.let { currentPos ->
if (currentPos < 0) return@let
viewpager?.setCurrentItem(currentPos, false)
savedInstanceState.remove(VIEWPAGER_ITEM_KEY)
// Using remove() sets the key to 0 instead of removing it
savedInstanceState.putInt(VIEWPAGER_ITEM_KEY, -1)
}
// Since the animation to scroll multiple items is so much its better to just hide

View File

@ -974,6 +974,7 @@ open class ResultFragment : ResultTrailerPlayer() {
chip.isCheckable = false
chip.isFocusable = false
chip.isClickable = false
chip.setTextColor(context.colorFromAttribute(R.attr.textColor))
addView(chip)
}
}

View File

@ -166,12 +166,12 @@
app:layout_scrollFlags="noScroll"
app:tabGravity="center"
app:tabIndicator="@drawable/indicator_background"
app:tabIndicatorColor="@color/textColor"
app:tabIndicatorColor="?attr/white"
app:tabIndicatorGravity="center"
app:tabIndicatorHeight="30dp"
app:tabMode="scrollable"
app:tabSelectedTextColor="@color/lightTextColor"
app:tabSelectedTextColor="?attr/primaryBlackBackground"
app:tabTextAppearance="@style/TabNoCaps"
app:tabTextColor="@color/textColor" />
app:tabTextColor="?attr/textColor" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>

View File

@ -23,7 +23,7 @@
android:elevation="10dp"
app:cardBackgroundColor="?attr/primaryGrayBackground"
app:cardCornerRadius="@dimen/rounded_image_radius"
app:layout_constraintDimensionRatio="1:1.414"
app:layout_constraintDimensionRatio="1:1.5"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">

View File

@ -100,6 +100,7 @@
<style name="ChipParent">
<item name="chipSpacingVertical">5dp</item>
<item name="chipSpacingHorizontal">5dp</item>
<item name="textColor">?attr/textColor</item>
</style>
<style name="AmoledMode">