Setting `bitmapData` on Bitmap doesn't seem to do anything

I have some unexpected results occurring in my engine which is rather annoying and inexplicible.

The baseImgSrc is checked to identify if the string is null or not, in case the user does not specify an image, and if not, it creates a blue background instead. But neither seems to qualify, even after triple-checking the file location and spelling (and it is definitely correct), no amount of changes seem to allow it to render at all.

This is unusual, because the same behaviour works for the Buttons as seen in the below Gist:

Well, almost the same code, but I’m sure you get the idea. I will in fact make the code structure the same as it is in the Button just to be sure, but if that does not work, what are your thoughts?

Here are the results:

If bitmapData were null, a blue background (default colour) would appear as the background, but this does not render either, which makes the former condition more probable.

You can test this bug and download the current state of the repo here.

Thank you in advance.

Does your project work on more than one target? Knowing if this occurs always, or only under the GL, Cairo, Canvas, Flash or DOM renderer would really help. Thanks! :slight_smile:


Okay, nevermind. I completely overlooked this, since I am doing removeChildren call I was removing the bitmap image without realising. I just needed to add it back in >.<

I am laughing and ashamed.