开发者

How to add parameters in Alert Event Listener in Flex [duplicate]

This question already has answers here: Flex: Sending parameters to Alert closeH开发者_StackOverflow社区andler (4 answers) Closed 7 years ago.

I know I can create a custom event and associate data with it and retrieve it in respective Event Listener. But What I am interested to know is, is there a short method (without having to extend Alert Event Class) to associate parameters to its alert Listener.


I answered a (very) similar question here. I hope this helps!

For anyone else looking into this, I added a quick code example here.


Not really.

You could use global variables of some sort and just reference those variables. Depending on your architecture this could be trivial, or no issue. In most cases this will break encapsulation, though and it generally not the preferred approach.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜