Normally, when using the Image class, if you omit the dimensions, Flex 
will default the image to its real width/height. However, I'm running 
into a situation in that Flex is defaulting the dimensions to 0,0 (if 
omitting explicit dimensions). Has anyone else ever encounted this 
issue?

As for some general details of its useage, I'm instantiating a new 
instance of the Image() class (rather then using the <mx:Image> tag), 
and it's being used as private class variable in a custom container 
(based off the Container class).  The image is being defined as a class 
variable and then instantiated with its source in the createChildren() 
method.

Being as though this is a runtime image (and therefore won't know and 
won't be able to hardcode the dimensions), I'm having to listen for the 
image load complete event to detect what the dimensions should be, and 
then set them explicitly.  This works, but I'd like to find out why the 
default sizing behavior isn't working correctly.


Reply via email to