summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Fabian Kozynski <kozynski@google.com> 2021-04-08 16:24:33 +0000
committer Android (Google) Code Review <android-gerrit@google.com> 2021-04-08 16:24:33 +0000
commitbd888709ffcd1b34a84dde90852ca431f844b668 (patch)
tree6b1a58378eb0b667c0a1c7bc45902f289db4fc11
parente7edb005c5d8f4e9c5be2a3a9d2120f9b919cf98 (diff)
parent0f69d9608f9e52a2ff3c301326eb963a17ac6178 (diff)
Merge "Set callback for the color background in the tile" into sc-dev
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSTileViewHorizontal.kt6
1 files changed, 5 insertions, 1 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSTileViewHorizontal.kt b/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSTileViewHorizontal.kt
index 7a8b2c696fa0..b9533237e3d5 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSTileViewHorizontal.kt
+++ b/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSTileViewHorizontal.kt
@@ -118,7 +118,11 @@ open class QSTileViewHorizontal(
override fun setClickable(clickable: Boolean) {
super.setClickable(clickable)
background = if (clickable && mShowRippleEffect) {
- mTileBackground
+ mRipple?.also {
+ // In case that the colorBackgroundDrawable was used as the background, make sure
+ // it has the correct callback instead of null
+ colorBackgroundDrawable?.callback = it
+ }
} else {
colorBackgroundDrawable
}