if (bg.image != null) { bg.image.freeSurface(); }
    void doSetBackground(Background background) {	BackgroundRetained bg; 	if (this.background != null) {	    bg = (BackgroundRetained)this.background.retained;	    bg.setInImmCtx(false);	    if (bg.image != null) {		bg.image.freeSurface();	    }	}	bg = (BackgroundRetained)background.retained;	bg.setInImmCtx(true);	if (bg.image != null) {		    bg.image.freeSurface();	}	this.background = background;    }