致命异常:无法膨胀内容视图java.lang.IllegalArgumentException:setShowActionsInCompactView:操作 0 越界(最大 -1)



我使用测试实验室找到我的应用程序上的bug,我有一个,但我找不到起源。我想它来自just_audio或audio_service。

这是测试问题:

android.app.RemoteServiceException: Bad notification(tag=null, id=1124) posted from package com.our_unseen_nature, crashing app(uid=10274, pid=22490): Couldn't inflate contentViewsjava.lang.IllegalArgumentException: setShowActionsInCompactView: action 0 out of bounds (max -1)
FATAL EXCEPTION: main
Process: com.our_unseen_nature, PID: 22490
android.app.RemoteServiceException: Bad notification(tag=null, id=1124) posted from package com.our_unseen_nature, crashing app(uid=10274, pid=22490): Couldn't inflate contentViewsjava.lang.IllegalArgumentException: setShowActionsInCompactView: action 0 out of bounds (max -1)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2005)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:223)
at android.app.ActivityThread.main(ActivityThread.java:7664)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)

谢谢大家。

谢谢大家,我已经找到了解决方案,这真的很容易。这个错误的发生是因为我没有正确地选择在Android的紧凑视图中显示的基于我选择作为我的控件的操作。

controls: [
MediaControl. skipToPrevious,
MediaControl.pause,
MediaControl.skipToNext,
],

// Which controls to show in Android's compact view
//from the lists of controls selected.
androidCompactActionIndices: const[0, 1, 2],

相关内容

  • 没有找到相关文章

最新更新