Skip to content
This repository has been archived by the owner on Jan 10, 2020. It is now read-only.

[Android] OPACITY is not a constant in com.facebook.keyframes.model.KFAnimation$PropertyType #78

Closed
camaron-izeni opened this issue Dec 22, 2016 · 6 comments

Comments

@camaron-izeni
Copy link

camaron-izeni commented Dec 22, 2016

One of the animations I'm trying to load has a feature with an OPACITY property.

{
          "property": "OPACITY",
          "key_values": [
            {
              "start_frame": 6,
              "data": [
                0
              ]
            },
            {
              "start_frame": 12,
              "data": [
                100
              ]
            }
          ],...
}

The Keyframes Android framework is not handling this properly.

FATAL EXCEPTION: main
Process: com.owletcare.owletfield, PID: 11924
java.lang.IllegalArgumentException: OPACITY is not a constant in com.facebook.keyframes.model.KFAnimation$PropertyType
at java.lang.Enum.valueOf(Enum.java:200)
at com.facebook.keyframes.model.KFAnimation$PropertyType.valueOf(KFAnimation.java:41)
at com.facebook.keyframes.deserializers.KFAnimationDeserializer.readObject(KFAnimationDeserializer.java:40)
at com.facebook.keyframes.deserializers.KFAnimationDeserializer$1.readObjectImpl(KFAnimationDeserializer.java:29)
at com.facebook.keyframes.deserializers.KFAnimationDeserializer$1.readObjectImpl(KFAnimationDeserializer.java:26)
at com.facebook.keyframes.deserializers.AbstractListDeserializer.readList(AbstractListDeserializer.java:35)
at com.facebook.keyframes.deserializers.KFFeatureDeserializer.readObject(KFFeatureDeserializer.java:71)
at com.facebook.keyframes.deserializers.KFFeatureDeserializer$1.readObjectImpl(KFFeatureDeserializer.java:32)
at com.facebook.keyframes.deserializers.KFFeatureDeserializer$1.readObjectImpl(KFFeatureDeserializer.java:29)
at com.facebook.keyframes.deserializers.AbstractListDeserializer.readList(AbstractListDeserializer.java:35)
at com.facebook.keyframes.deserializers.KFImageDeserializer.readObject(KFImageDeserializer.java:52)
at com.facebook.keyframes.deserializers.KFImageDeserializer.deserialize(KFImageDeserializer.java:35)
at com.owletcare.owlet.controls.KeyframesSequence.load(KeyframesSequence.java:78)
at com.owletcare.owlet.controls.KeyframesSequence.<init>(KeyframesSequence.java:68)
at com.owletcare.owlet.fragments.vitalsHelpPages.VHFeedingFragment.onViewCreated(VHFeedingFragment.java:37)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1132)
at android.support.v4.app.FragmentManagerImpl.moveToState(FragmentManager.java:1295)
at android.support.v4.app.BackStackRecord.run(BackStackRecord.java:801)
at android.support.v4.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1682)
at android.support.v4.app.FragmentManagerImpl$1.run(FragmentManager.java:541)
at android.os.Handler.handleCallback(Handler.java:746)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5459)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:728)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)

This error is coming from the current build on Gradle. The animation runs fine when I run it on a clone of the current repository.

I suggest a new build be released to Gradle as soon as possible.

@lozzle
Copy link
Contributor

lozzle commented Dec 22, 2016

Hi @camaron-izeni-- you're right. The current release version (1.0.0) is before we added some new features (opacity, anchor point animation). You can get an updated version from the repo and Opacity should be working on Android.

@camaron-izeni
Copy link
Author

Any idea when the next release will be pushed out?

@lozzle
Copy link
Contributor

lozzle commented Dec 22, 2016

We'd have to sync up and make sure all of the new features are supported across iOS/exporter as well, and we could release a new version. Unsure how long that will take since many of us are on holiday ATM.

@camaron-izeni
Copy link
Author

Understood, thanks for the quick reply.

@m1ga
Copy link
Contributor

m1ga commented Dec 23, 2016

@camaron-izeni if you want to test it I've compiled a version from the current branch: http://migaweb.de/keyframes-1.0_test.jar
Opacity is working fine on android!

@lozzle
Copy link
Contributor

lozzle commented Dec 25, 2016

thanks, @m1ga!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants