gpt4 book ai didi

android - 三星盖乐世 S6/7/8 - RuntimeException/throwIfCannotDraw

转载 作者:太空宇宙 更新时间:2023-11-03 11:00:29 24 4
gpt4 key购买 nike

最近随着 android 7.0.0 的出现和设备的出现,我的应用开始无缘无故地抛出异常。问题是我不知道可能是什么问题 - 我所知道的是它只发生在带有 Nougat 的三星设备上并且它是关于绘制一些 ImageViews 的。像 Admob 或 Universal-Image-Loader 这样的库可以这样做吗?

无论如何这是完整的异常(exception) - 希望有人能帮助我......

java.lang.RuntimeException: 
at android.view.DisplayListCanvas.throwIfCannotDraw(DisplayListCanvas.java:260)
at android.graphics.Canvas.drawBitmap(Canvas.java:1420)
at android.graphics.drawable.BitmapDrawable.draw(BitmapDrawable.java:545)
at android.widget.ImageView.onDraw(ImageView.java:1286)
at android.view.View.draw(View.java:18313)
at android.view.View.updateDisplayListIfDirty(View.java:17291)
at android.view.View.draw(View.java:18075)
at android.view.ViewGroup.drawChild(ViewGroup.java:3966)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3752)
at android.view.View.updateDisplayListIfDirty(View.java:17286)
at android.view.View.draw(View.java:18075)
at android.view.ViewGroup.drawChild(ViewGroup.java:3966)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3752)
at android.view.View.draw(View.java:18316)
at android.view.View.updateDisplayListIfDirty(View.java:17291)
at android.view.View.draw(View.java:18075)
at android.view.ViewGroup.drawChild(ViewGroup.java:3966)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3752)
at android.view.View.updateDisplayListIfDirty(View.java:17286)
at android.view.View.draw(View.java:18075)
at android.view.ViewGroup.drawChild(ViewGroup.java:3966)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3752)
at android.view.View.updateDisplayListIfDirty(View.java:17286)
at android.view.View.draw(View.java:18075)
at android.view.ViewGroup.drawChild(ViewGroup.java:3966)
at android.view.ViewGroup.dispatchDraw(ViewGroup.java:3752)
at android.view.View.draw(View.java:18316)
at com.android.internal.policy.DecorView.draw(DecorView.java:850)
at android.view.View.updateDisplayListIfDirty(View.java:17291)
at android.view.ThreadedRenderer.updateViewTreeDisplayList(ThreadedRenderer.java:666)
at android.view.ThreadedRenderer.updateRootDisplayList(ThreadedRenderer.java:672)
at android.view.ThreadedRenderer.draw(ThreadedRenderer.java:780)
at android.view.ViewRootImpl.draw(ViewRootImpl.java:3103)
at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2899)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2493)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1493)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:7040)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:927)
at android.view.Choreographer.doCallbacks(Choreographer.java:702)
at android.view.Choreographer.doFrame(Choreographer.java:638)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:913)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6688)
at java.lang.reflect.Method.invoke(Native Method:0)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1468)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1358)

最佳答案

能否请您检查位图在绘制之前是否被回收?

关于android - 三星盖乐世 S6/7/8 - RuntimeException/throwIfCannotDraw,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45065360/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com