¡@

Home 

2014/10/16 ¤W¤È 08:10:27

android Programming Glossary: ball_red

Using Android getIdentifier()

http://stackoverflow.com/questions/15488238/using-android-getidentifier

I've tried this r Resources.getSystem .getIdentifier ball_red drawable com.Juggle2 Log.i FindBall R r And this r Resources.getSystem.. r Resources.getSystem .getIdentifier com.Juggle2 drawable ball_red null null But 'r' always ends up as zero. I'm calling this line.. pass it from my SurfaceView . Eventually I want to replace ball_red with a variable but first thing's first. This isn't working...

Using Android getIdentifier()

http://stackoverflow.com/questions/15488238/using-android-getidentifier

Android getIdentifier I've tried this r Resources.getSystem .getIdentifier ball_red drawable com.Juggle2 Log.i FindBall R r And this r Resources.getSystem .getIdentifier com.Juggle2 drawable ball_red null.. ball_red drawable com.Juggle2 Log.i FindBall R r And this r Resources.getSystem .getIdentifier com.Juggle2 drawable ball_red null null But 'r' always ends up as zero. I'm calling this line from inside a helper class that's not an Activity and doesn't.. anything so I can't simply call getResources but I can pass it from my SurfaceView . Eventually I want to replace ball_red with a variable but first thing's first. This isn't working. com.Juggle2 is indeed my package name. drawable is the res..