Change selection ripple to accent color
Change the selection ripple so that it matches the chosen accent color.
This commit is contained in:
parent
5827ca492c
commit
ce687cd515
6 changed files with 14 additions and 3 deletions
|
|
@ -23,7 +23,6 @@ class MainActivity : AppCompatActivity() {
|
||||||
|
|
||||||
override fun onCreate(savedInstanceState: Bundle?) {
|
override fun onCreate(savedInstanceState: Bundle?) {
|
||||||
super.onCreate(savedInstanceState)
|
super.onCreate(savedInstanceState)
|
||||||
|
|
||||||
setContentView(R.layout.activity_main)
|
setContentView(R.layout.activity_main)
|
||||||
|
|
||||||
Log.d(this::class.simpleName, "Activity Created.")
|
Log.d(this::class.simpleName, "Activity Created.")
|
||||||
|
|
|
||||||
10
app/src/main/res/drawable/ripple.xml
Normal file
10
app/src/main/res/drawable/ripple.xml
Normal file
|
|
@ -0,0 +1,10 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
android:color="?attr/colorPrimary">
|
||||||
|
<!-- TODO: Find better color to override -->
|
||||||
|
<item android:id="@android:id/mask">
|
||||||
|
<shape android:shape="rectangle">
|
||||||
|
<solid android:color="?attr/colorPrimary" />
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</ripple>
|
||||||
|
|
@ -13,7 +13,7 @@
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?android:attr/selectableItemBackground"
|
android:background="@drawable/ripple"
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:padding="@dimen/padding_medium">
|
android:padding="@dimen/padding_medium">
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@
|
||||||
<androidx.constraintlayout.widget.ConstraintLayout
|
<androidx.constraintlayout.widget.ConstraintLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?android:attr/selectableItemBackground"
|
android:background="@drawable/ripple"
|
||||||
android:clickable="true"
|
android:clickable="true"
|
||||||
android:focusable="true"
|
android:focusable="true"
|
||||||
android:padding="@dimen/padding_medium">
|
android:padding="@dimen/padding_medium">
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
<resources>
|
<resources>
|
||||||
<color name="background">#151515</color>
|
<color name="background">#151515</color>
|
||||||
<color name="divider_color">#6d6d6d</color>
|
<color name="divider_color">#6d6d6d</color>
|
||||||
|
<color name="selection_color">#484848</color>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Base color set derived from Music Player GO.
|
Base color set derived from Music Player GO.
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
<resources>
|
<resources>
|
||||||
<color name="background">#fafafa</color>
|
<color name="background">#fafafa</color>
|
||||||
<color name="divider_color">#6d6d6d</color>
|
<color name="divider_color">#6d6d6d</color>
|
||||||
|
<color name="selection_color">#cbcbcb</color>
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Base color set derived from Music Player GO.
|
Base color set derived from Music Player GO.
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue