Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Adobe AIR Development

Posts: 141
Registered: ‎02-10-2010
My Device: 9500
My Carrier: Airtel

Listening to Events

I have developed an application that uses 2 containers and adds TextInput UI control to one of the containers. I am able to catch the click event if i add the control directly to stage. However, when added to the container, i am unable to catch the events for that control. Do i need to do anything extra to listen for events when adding controls to a container.

Any clues are highly appreciated.



Posts: 6,541
Registered: ‎10-27-2010
My Device: HTC One, PlayBook, LE Z10, DE Q10
My Carrier: Verizon

Re: Listening to Events

What event are you listening to?  Sounds like you need to move the addEventListener to the container instead of the stage.  If you are listening to some event to the text input (like "change"), then you should be adding the event listener to the text input control.  In general, you add the event listener to the object producing the event.