diff options
author | Alan Viverette <alanv@google.com> | 2015-08-20 20:44:40 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-08-20 20:44:40 +0000 |
commit | 63e9875a3d39cd46e874cba840f51ee35c1b7fa4 (patch) | |
tree | 5626ae5b22630ec9a221756bc168320570b4ba44 | |
parent | 78985f3fb5b424d3d4010cbe83ac85c4ea4b7fc6 (diff) | |
parent | 786529f2d15fe9b9083eb9ac46c8305f29cdf8e9 (diff) | |
download | frameworks_base-63e9875a3d39cd46e874cba840f51ee35c1b7fa4.zip frameworks_base-63e9875a3d39cd46e874cba840f51ee35c1b7fa4.tar.gz frameworks_base-63e9875a3d39cd46e874cba840f51ee35c1b7fa4.tar.bz2 |
am 786529f2: am 54c807e7: Merge "Translate ripple mask to account for drawable bounds" into mnc-dev
* commit '786529f2d15fe9b9083eb9ac46c8305f29cdf8e9':
Translate ripple mask to account for drawable bounds
-rw-r--r-- | graphics/java/android/graphics/drawable/RippleDrawable.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/graphics/java/android/graphics/drawable/RippleDrawable.java b/graphics/java/android/graphics/drawable/RippleDrawable.java index 32f6a89..464f3de 100644 --- a/graphics/java/android/graphics/drawable/RippleDrawable.java +++ b/graphics/java/android/graphics/drawable/RippleDrawable.java @@ -855,7 +855,8 @@ public class RippleDrawable extends LayerDrawable { // Position the shader to account for canvas translation. if (mMaskShader != null) { - mMaskMatrix.setTranslate(-x, -y); + final Rect bounds = getBounds(); + mMaskMatrix.setTranslate(bounds.left - x, bounds.top - y); mMaskShader.setLocalMatrix(mMaskMatrix); } |