Reputation: 1523
I'm working on an Android game with Eclipse, suddenly appears lots of errors in the code. Eclipse now don't recognize R.drawable resources .... Console shows the following warning: libpng warning: Ignoring gAMA chunk with gamma=0
What can I do to continue as it was?
Upvotes: 3
Views: 4371
Reputation: 1523
I found the solution. seems there was an error in the import of the R file (resources file). I replaced import android.R for import package.name.R
Thanks for the help
Upvotes: 8
Reputation: 39470
Did you try Cleaning and Building the project? Go to Project > Clean and clean your project. Then try running it again. Most of the time when I see problems with my R.java a clean and build will fix it.
If that doesn't help, can you paste your code or a sampling of it?
Upvotes: 1
Reputation: 87
I'm definetly not the most advanced guy out here but I have lost my R.java file more than a couple of times. You lose the whole thing whenever there is one thing that should be added but has an error. So almost all of those errors that you are seeing are secondary errors. Did you add an image or some other type of resource that you can think of when you lost your r.java?
Upvotes: 1