Hi Kirupians,
I’m running into a very strange issue when testing an application I’m building online: loaded images aren’t showing.
When testing locally everything works fine.
I’m retrieving the images from an Adobe Scene7 server, and there’s a crossdomain.xml in place there with the correct entries. I’m getting the right bytesLoaded and bytesTotal. I’m not getting an IOError Event.
What could be wrong?
Here’s a piece of the offending code: (I replaced Event.COMPLETE with Event.INIT, hoping it might make a difference, but it doesn’t)
[AS]loader.contentLoaderInfo.addEventListener(Event.INIT, onImageComplete);
loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, onIOError);
private function onImageComplete(event:Event):void {
loader.contentLoaderInfo.removeEventListener(Event.INIT, onImageComplete);
loader.contentLoaderInfo.removeEventListener(IOErrorEvent.IO_ERROR, onIOError);
bmp = event.target.content;
bmp.smoothing = true;
bmp.width = nWidth;
bmp.height = nHeight;
imageHolder.addChild(bmp);
TweenMax.to(imageHolder, 1, {alpha:1});
dispatchEvent(new Event("IMAGE_COMPLETE", true));
}
[/AS]