I have the following:
public class ExampleObject extends GridObject {
private static Context c;
private static final String name = "Example Object";
private static Bitmap skin = BitmapFactory.decodeResource(c.getResources(), R.drawable.defaultObject );
private static float x,y;
public ExampleObject(Context c, float x, float y) {
this.c = c;
this.x = x;
this.y = y;
}
}
The class has 3 static class members, The image is a decoded bitmap, I want it to be decoded once and once only for use on ALL instances of this object.
In it's current state is this achieved? or is it decoded every time an instance of this class is created?
How should it be done?