Warn when there are expressions in the composition
diff --git a/lottie/src/main/java/com/airbnb/lottie/AnimatableFloatValue.java b/lottie/src/main/java/com/airbnb/lottie/AnimatableFloatValue.java
index ffd299b..3bbce6e 100644
--- a/lottie/src/main/java/com/airbnb/lottie/AnimatableFloatValue.java
+++ b/lottie/src/main/java/com/airbnb/lottie/AnimatableFloatValue.java
@@ -1,5 +1,7 @@
package com.airbnb.lottie;
+import android.util.Log;
+
import org.json.JSONObject;
import java.util.List;
@@ -51,6 +53,9 @@
static AnimatableFloatValue newInstance(JSONObject json, LottieComposition composition,
boolean isDp) {
float scale = isDp ? composition.getDpScale() : 1f;
+ if (json.has("x")) {
+ Log.w(L.TAG, "Animation has expressions which are not supported.");
+ }
AnimatableValueParser.Result<Float> result = AnimatableValueParser
.newInstance(json, scale, composition, ValueFactory.INSTANCE)
.parseJson();
diff --git a/lottie/src/main/java/com/airbnb/lottie/AnimatableIntegerValue.java b/lottie/src/main/java/com/airbnb/lottie/AnimatableIntegerValue.java
index a1420bf..faf18bf 100644
--- a/lottie/src/main/java/com/airbnb/lottie/AnimatableIntegerValue.java
+++ b/lottie/src/main/java/com/airbnb/lottie/AnimatableIntegerValue.java
@@ -1,5 +1,7 @@
package com.airbnb.lottie;
+import android.util.Log;
+
import org.json.JSONObject;
import java.util.List;
@@ -35,6 +37,9 @@
static AnimatableIntegerValue newInstance(
JSONObject json, LottieComposition composition) {
+ if (json.has("x")) {
+ Log.w(L.TAG, "Animation has expressions which are not supported.");
+ }
AnimatableValueParser.Result<Integer> result = AnimatableValueParser
.newInstance(json, 1, composition, ValueFactory.INSTANCE)
.parseJson();