Closed shikibu9419 closed 3 years ago
記事に飛んだ後、カルーセルが消えちゃう
エラー出てる
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.newsee, PID: 18261
java.lang.RuntimeException: Unable to stop service com.example.newsee.OverlayService@c784347: java.lang.IllegalStateException: Not allowed to start service Intent { act=STOP cmp=com.example.newsee/.ViewPagerAutoScrollService }: app is in background uid UidRecord{e51684 u0a243 SVC bg:+13d13h48m18s557ms idle change:idle procs:1 seq(0,0,0)}
at android.app.ActivityThread.handleStopService(ActivityThread.java:4375)
at android.app.ActivityThread.access$1900(ActivityThread.java:237)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1956)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:223)
at android.app.ActivityThread.main(ActivityThread.java:7656)
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)
Caused by: java.lang.IllegalStateException: Not allowed to start service Intent { act=STOP cmp=com.example.newsee/.ViewPagerAutoScrollService }: app is in background uid UidRecord{e51684 u0a243 SVC bg:+13d13h48m18s557ms idle change:idle procs:1 seq(0,0,0)}
at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1715)
at android.app.ContextImpl.startService(ContextImpl.java:1670)
at android.content.ContextWrapper.startService(ContextWrapper.java:720)
at com.example.newsee.ViewPagerAutoScrollService$Companion.stop(ViewPagerAutoScrollService.kt:38)
at com.example.newsee.OverlayService.onDestroy(OverlayService.kt:107)
at android.app.ActivityThread.handleStopService(ActivityThread.java:4355)
close #12