Can't toast on a thread that has not called Looper.prepare()
生活随笔
收集整理的這篇文章主要介紹了
Can't toast on a thread that has not called Looper.prepare()
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
這個錯誤說了就是子線程直接彈Toast
就說下我的處理方法
Looper.prepare();Toast.makeText(MainActivity.this, "11111", Toast.LENGTH_SHORT).show();Looper.loop();
這樣就可了,
?
總結
以上是生活随笔為你收集整理的Can't toast on a thread that has not called Looper.prepare()的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 48寸的海尔电视换个屏多少钱
- 下一篇: ProgreassBar 60秒走完,