thejchaps

Communicating between widgets without modifying one of the widgets

Discussion created by thejchaps on Jun 12, 2013
Latest reply on Jun 13, 2013 by thejchaps
I have one widget that I cannot modify. It takes a GeoRSS file, adds points to the map with a marker and also places more info in an InfoWindow (the infoWindowRender is a PopUpRenderer) which appears when the user clicks the point.

I need to somehow communicate to another widget which I am developing, passing a single datum (a uid).

I'm not really sure if there is a way to do this without modifying the first widget, however I discovered that the infoWindow accepts html links, and that you can listen for links prefixed with "event:" via http://circlecube.com/2008/12/asfunction-texteventlink-tutorial-for-as3-flash-html-link-to-call-actionscript-function-tutorial/.

So now I'm wondering if there is any way to get a reference to the text in the infoWindow so that I can attach this listener, or if there is a better way to pass the id between the two widgets (because my way seems pretty odd).

Thanks

Outcomes