This content has been marked as final. Show 4 replies
Not sure if you know this, but you can set a click attribute to your image.
<mx:Image x="0" y="0" width="500" height="400" source="../assets/help_numbers.png" click="trace('sss')" />
So, when people click on the picture, they are actually clicking the picture and not some button they don't see. Does this help? Maybe I'm missing the point of a button behind a picture...
thank you for posting.
The Button is totaly behind the Image. If the Image is transparent, you can see through the Image and see the button.
I know how to trap the click on the Image by adding the click attribute. However, that's not what I want.
I would like the Image to ignore the click and the button behind it should trap the click. In that way, the
Image should literaly be transparent in terms of both visibility and user interaction.
Well if the image is transparent visually, then all you will see is the button behind it, which defeats the purpose of having an image component in the first place. Transparency is clear, unobstructed -- such as a glass window. Maybe you didn't mean to say it should be transparent visibly, but that I cannot assume.
I'm still curious as to the reasoning behind what you are trying to accomplish. I'd like to know just in case there's a better way to handle what you wish to do. As far as I know, interaction can only come from objects at the top level. So having a button on a level below the image is no different than if there wasn't a button at all.
I was looking for this too. So for the next guy who needs it, you set the mouseEnabled of the top clip to false. If the top clip has child objects, you'll have to set it for them, or use mouseChildren.