summaryrefslogtreecommitdiffstats
path: root/graphics
diff options
context:
space:
mode:
authorAlan Viverette <alanv@google.com>2015-05-04 12:51:54 -0700
committerAlan Viverette <alanv@google.com>2015-05-04 12:51:54 -0700
commitd21be499753b964433faefbe0fd770c62a4c2e12 (patch)
tree21b13b793f6f6b545b059311d235e50c9dd73285 /graphics
parent5551aca2b8ec9fe7ab5ffda8dad82ee104556962 (diff)
downloadframeworks_base-d21be499753b964433faefbe0fd770c62a4c2e12.zip
frameworks_base-d21be499753b964433faefbe0fd770c62a4c2e12.tar.gz
frameworks_base-d21be499753b964433faefbe0fd770c62a4c2e12.tar.bz2
More documentation for handling RippleDrawable mask at run time
The docs are now really explicit about the layer's ID and how to set or update the mask layer from code. Bug: 20493831 Change-Id: I801f10cd08fd1b4bb226c63a1bdf3271229928ea
Diffstat (limited to 'graphics')
-rw-r--r--graphics/java/android/graphics/drawable/RippleDrawable.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/graphics/java/android/graphics/drawable/RippleDrawable.java b/graphics/java/android/graphics/drawable/RippleDrawable.java
index f67dcb3..efc171c 100644
--- a/graphics/java/android/graphics/drawable/RippleDrawable.java
+++ b/graphics/java/android/graphics/drawable/RippleDrawable.java
@@ -53,8 +53,11 @@ import java.util.Arrays;
* attribute identifier.
* <p>
* A touch feedback drawable may contain multiple child layers, including a
- * special mask layer that is not drawn to the screen. A single layer may be set
- * as the mask by specifying its android:id value as {@link android.R.id#mask}.
+ * special mask layer that is not drawn to the screen. A single layer may be
+ * set as the mask from XML by specifying its {@code android:id} value as
+ * {@link android.R.id#mask}. At run time, a single layer may be set as the
+ * mask using {@code setId(..., android.R.id.mask)} or an existing mask layer
+ * may be replaced using {@code setDrawableByLayerId(android.R.id.mask, ...)}.
* <pre>
* <code>&lt!-- A red ripple masked against an opaque rectangle. --/>
* &ltripple android:color="#ffff0000">