My view -> mediator signals are just vanilla signals that are properties of the view. The fact that the mediator-view relationship is 1:1 means you don't need to further identify it with a class for injection - just expose it with a getter.
This works and seems cleaner straight away. But when you say my
signal can simply be new Signal(somePropTypes...), are you
suggesting I can create the signal at the time of dispatching it
rather than in two steps?
I was suggesting you create the signal as a property - as you have here, except that you'll need to declare the return type so that you can send that selectedIndex property in the dispatch. I'm afraid I'm a pure-as3-only girl so I don't know the mxml equivalent of new Signal(uint)... but I'm sure you do.
Your second attempt is ok. You just did what Stray meant. In
declaration field you introduced a property (after compilation it's
converted to getter/setter. She also suggested you to introduce
value classes - type of dispatched values. You can also do it in
MXML like this:
And just one tip from me. If your view dispatches the same type
of values as mediator injected signals you can assign injected
signals in Mediator to your view instance. It should be done in
onRegister. Then you don't need to listen and dispatch in Mediator.
But you should remember that the instance of signal previously
created by the view will disappear.