Improve setAnimation docs
diff --git a/lottie/src/main/java/com/airbnb/lottie/LottieAnimationView.java b/lottie/src/main/java/com/airbnb/lottie/LottieAnimationView.java index 1acd9d0..4c3513e 100644 --- a/lottie/src/main/java/com/airbnb/lottie/LottieAnimationView.java +++ b/lottie/src/main/java/com/airbnb/lottie/LottieAnimationView.java
@@ -420,7 +420,10 @@ /** * @see #setAnimation(JsonReader) which is more efficient than using a JSONObject. - * For animations loaded from the network, use {@link #setAnimationFromJson(String)} + * For animations loaded from the network, use {@link #setAnimationFromJson(String)}. + * + * If you must use a JSONObject, you can convert it to a StreamReader with: + * `new JsonReader(new StringReader(json.toString()));` */ @Deprecated public void setAnimation(JSONObject json) {
diff --git a/lottie/src/main/java/com/airbnb/lottie/LottieComposition.java b/lottie/src/main/java/com/airbnb/lottie/LottieComposition.java index 33c0edb..e2df5a7 100644 --- a/lottie/src/main/java/com/airbnb/lottie/LottieComposition.java +++ b/lottie/src/main/java/com/airbnb/lottie/LottieComposition.java
@@ -37,7 +37,7 @@ */ public class LottieComposition { - final PerformanceTracker performanceTracker = new PerformanceTracker(); + private final PerformanceTracker performanceTracker = new PerformanceTracker(); final Map<String, List<Layer>> precomps = new HashMap<>(); final Map<String, LottieImageAsset> images = new HashMap<>(); /** Map of font names to fonts */ @@ -152,7 +152,7 @@ return sb.toString(); } - @SuppressWarnings({"WeakerAccess", "unused"}) + @SuppressWarnings({"WeakerAccess"}) public static class Factory { private Factory() { }