应用有太多线程的问题

应用有太多线程的问题

http://img1.sycdn.imooc.com//climg/5e6b46f3087409e105420278.jpg

http://img1.sycdn.imooc.com//climg/5e6b46f308c091a216000786.jpg

这个是图片太多,然后加载不出来吗

正在回答

登陆购买课程后可参与讨论,去登陆

6回答

1)再往下找log。从上往下找,出现第一次你写的类的地方,对应的还有行号。就是在那里出的问题。 2)你的图片在哪个文件夹下?不管是在哪里,请一定要复制一份放在drawable里。不是drawable-xxx,而是drawable哈。祝:学习愉快

  • 晓峰666 提问者 #1
    就是在drawable里面,看了下面的log没找到我写类的地方
    2020-03-13 18:23:01
  • 好帮手慕雪 回复 提问者 晓峰666 #2
    提示你代码里有太多的耗时操作,应该是你的图片太大了。或者就是文件夹放的地方不对
    2020-03-13 20:06:32
  • 晓峰666 提问者 回复 好帮手慕雪 #3
    图片多少是大啊
    2020-03-13 20:11:19
提问者 晓峰666 2020-03-16 12:21:27

http://img1.sycdn.imooc.com//climg/5e6efe9908405a5410410761.jpg我在网上找到这个,但是没看明白,他说数据设置错了,

  • 提问者 晓峰666 #1
    明白了,不是文件夹的问题,是我自己代码的问题
    2020-03-16 13:15:23
提问者 晓峰666 2020-03-14 22:56:39

http://img1.sycdn.imooc.com//climg/5e6cef350865140b16000880.jpghttp://img1.sycdn.imooc.com//climg/5e6cf08308c8ef3706980772.jpg单独做了一个Demo也是这个情况   下面是报错情况

03-14 22:52:17.517 4721-4721/? I/art: Late-enabling -Xcheck:jni

03-14 22:52:17.535 4721-4731/? E/art: Failed sending reply to debugger: Broken pipe

03-14 22:52:17.535 4721-4731/? I/art: Debugger is no longer active

03-14 22:52:17.626 4721-4721/? W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter androidx.vectordrawable.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable

03-14 22:52:17.653 4721-4721/? I/art: Rejecting re-init on previously-failed class java.lang.Class<androidx.core.view.ViewCompat$2>

03-14 22:52:17.654 4721-4721/? I/art: Rejecting re-init on previously-failed class java.lang.Class<androidx.core.view.ViewCompat$2>

03-14 22:52:17.687 4721-4739/? D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true

03-14 22:52:17.689 4721-4721/? D/Atlas: Validating map...

03-14 22:52:17.710 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.710 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.725 4721-4739/? I/OpenGLRenderer: Initialized EGL, version 1.4

03-14 22:52:17.747 4721-4739/? D/OpenGLRenderer: Enabling debug mode 0

03-14 22:52:17.887 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.887 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.888 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.888 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.890 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.890 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.892 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.892 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.894 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.894 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.896 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.896 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.897 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.897 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.898 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.898 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.899 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.899 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.919 4721-4721/? W/art: Before Android 4.1, method int androidx.appcompat.widget.DropDownListView.lookForSelectablePosition(int, boolean) would have incorrectly overridden the package-private method in android.widget.ListView

03-14 22:52:17.923 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.923 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7

03-14 22:52:17.990 4721-4721/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@c1262f7: open failed: ENOENT (No such file or directory)

03-14 22:52:17.990 4721-4721/? I/System.out: resolveUri failed on bad bitmap uri: [I@c1262f7


  • 我已经给你说过多次了,多的那层文件夹删除。多的同名的图片删除。drawable下要有所有不同名字的图片。
    2020-03-16 10:05:51
  • 提问者 晓峰666 回复 好帮手慕雪 #2
    是drawable-v24删除吧
    2020-03-16 10:10:55
  • 提问者 晓峰666 回复 好帮手慕雪 #3
    哪一个多的文件夹,drawable下面没有同名的图片啊
    2020-03-16 10:24:03
好帮手慕雪 2020-03-14 20:28:39

http://img1.sycdn.imooc.com//climg/5e6ccd8809643c0203360352.jpg

你怎么还多建了一层文件夹呢?删除它。另外同一个名字,存在一个文件就行了,你的有太多的重复了。

  • 提问者 晓峰666 #1
    删除他报错,以前也有这个文件就没报错
    2020-03-14 21:25:02
  • 好帮手慕雪 回复 提问者 晓峰666 #2
    不可能的。你可以再测试一下。你增加一下ic_launcher文件夹后再测试别的项目,肯定也是跑不起来的。另外,如果.java没有改动的话,是不会重新生成APP的,也就是说它还是用的原来的APP。把上述两个情况都改了以后,(保留小的ic_launcher.png哈)再改一下java文件。加个空行什么的,再保存一下,并把原来的APP,从手机上,手动的删除一下。
    2020-03-14 21:39:42
  • 提问者 晓峰666 #3
    删了,图片还是原来那样,显示不出来
    2020-03-14 22:08:14
提问者 晓峰666 2020-03-13 21:40:03

03-13 19:24:37.659 7499-7499/? I/art: Late-enabling -Xcheck:jni

03-13 19:24:37.695 7499-7509/? I/art: Debugger is no longer active

03-13 19:24:37.803 7499-7499/? W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter androidx.vectordrawable.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable

03-13 19:24:37.828 7499-7499/? I/art: Rejecting re-init on previously-failed class java.lang.Class<androidx.core.view.ViewCompat$2>

03-13 19:24:37.828 7499-7499/? I/art: Rejecting re-init on previously-failed class java.lang.Class<androidx.core.view.ViewCompat$2>

03-13 19:24:37.854 7499-7517/? D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true

03-13 19:24:37.856 7499-7499/? D/Atlas: Validating map...

03-13 19:24:37.878 7499-7517/? I/OpenGLRenderer: Initialized EGL, version 1.4

03-13 19:24:37.908 7499-7517/? D/OpenGLRenderer: Enabling debug mode 0

03-13 19:24:39.729 7499-7509/? I/art: Ignoring second debugger -- accepting and dropping

03-13 19:24:55.945 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:55.945 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:55.946 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:55.946 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.218 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.218 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.220 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.220 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.220 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.220 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.222 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.222 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.224 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.224 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.228 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.228 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.229 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.229 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.231 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.231 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.232 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.232 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.234 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.234 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.396 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.396 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.398 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.398 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.562 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.562 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.563 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.563 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.564 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.564 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

03-13 19:24:56.565 7499-7499/? E/BitmapFactory: Unable to decode stream: java.io.FileNotFoundException: [I@98962f: open failed: ENOENT (No such file or directory)

03-13 19:24:56.565 7499-7499/? I/System.out: resolveUri failed on bad bitmap uri: [I@98962f

http://img1.sycdn.imooc.com//climg/5e6b8d2a08d82ab716000835.jpg

  • 提问者 晓峰666 #1
    刚才找到一个错,现在又换别的错了
    2020-03-13 21:40:56
提问者 晓峰666 2020-03-13 18:21:13
  • 你把课程中的图片放在哪个文件夹里了,是不是mipmap-hdpi中。你没改变动过图片吧?
    2020-03-13 20:04:47
  • 提问者 晓峰666 回复 好帮手慕雪 #2
    就在drawable里面,全都在它里面
    2020-03-13 20:09:50
问题已解决,确定采纳
还有疑问,暂不采纳

恭喜解决一个难题,获得1积分~

来为老师/同学的回答评分吧

0 星
请稍等 ...
意见反馈 帮助中心 APP下载
官方微信

在线咨询

领取优惠

免费试听

领取大纲

扫描二维码,添加
你的专属老师