summaryrefslogtreecommitdiff
path: root/core/java
diff options
context:
space:
mode:
authorDoris Liu <tianliu@google.com>2016-06-01 14:22:28 -0700
committerDoris Liu <tianliu@google.com>2016-06-09 14:39:18 -0700
commita57e95a6a351242941e5cef97aaaa1fb34f20a9d (patch)
tree0cc73ba256548b96263885690b4830871f8a47fc /core/java
parent3e03d02f7627f81b2a132c6d59057dfaf3e30324 (diff)
Throw Exception for wrong valueType with API guard
Previously, wrong valueType error is swallowed in jni. As a result, some animations are quietly skipped without letting developers know. This CL maintains that behavior for pre-N, and throws Exception to notify developers of the error for N and above. Bug: 29009391 Change-Id: I3e8f003cdb97d214da72af3f93a84f64797b1c2c (cherry picked from commit 94db09917a17976135e2c63d8e4171c54730c079)
Diffstat (limited to 'core/java')
-rw-r--r--core/java/android/animation/PropertyValuesHolder.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/core/java/android/animation/PropertyValuesHolder.java b/core/java/android/animation/PropertyValuesHolder.java
index 1dee925f2bdd..3e7cbbdd5533 100644
--- a/core/java/android/animation/PropertyValuesHolder.java
+++ b/core/java/android/animation/PropertyValuesHolder.java
@@ -1108,6 +1108,13 @@ public class PropertyValuesHolder implements Cloneable {
}
}
+ /**
+ * @hide
+ */
+ public Class getValueType() {
+ return mValueType;
+ }
+
@Override
public String toString() {
return mPropertyName + ": " + mKeyframes.toString();