Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
326 views
in Technique[技术] by (71.8m points)

android - Drawables not changing after being replaced with others in the folders

I've created a new theme set for an app of mine, and decided I didn't need the old one anymore. So, I copied my new image files over the old ones, replacing all of them. I did this for all of my drawables folders. I then recreated R.java just in case, and rebuild my application.

For some reason, it's picking up the old images and displaying those. Alright, I thought, must be something in the memory / cache. I'll just wipe my emulator image and try again.

After doing so, the app still used the old pictures. I thought I must have made a mistake and checked the images in Eclipse, but it showed the new images there. I then took drastic matters and deleted the drawables folders. Ofcourse this caused my project to freak out so I quickly added the desired new pictures and rebuild the project. No errors showed up, and all pictures appeared changed in Eclipse.

But when running the app, the old pictures still showed. Except in some parts of the app. Out of 70 or so pictures that I used, only 2 were now displaying the new version. All the other ones are still showing the old pictures.

What can be going on here? I tried restarting my emulator, resfreshing the project, creating a new project using the old one as the source, restarting my phone, wiping all app data before installing the app, deleting all images and replacing them with the new ones, but nothing seems to work.

How can an app that contains new images, thats being run on a completely fresh emulator, still display images that have been deleted at least an hour earlier?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Wipe your bin-folder to remove old compiled data.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...