rjava.lang.IllegalArgumentException on startActivity(intent,bundle animantion)

后端 未结 3 697
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-12-28 15:25

Hi I am using following code but sometimes app is crashing with error:

java.lang.IllegalArgumentException in startActivity(slideactivity, bndlanim

3条回答
  •  再見小時候
    2020-12-28 16:03

    I found the problem, after digging really deep I saw that there is some problem with the SDK > 21 so lollipop up. In my case this happens when using transparent theme together with some enter and exit transitions.

    Two options:

    If I remove the ActivityOptions.makeCustomAnimation().toBundle(); and work good again.

    If I set my theme to my app normal theme works good too.

    I will have to investigate further but I guess there is some configuration on the theme that makes this crash.

提交回复
热议问题