Autowired when components are removed and subsequent addChild is called
We use Spring Actionscript to wire ours Views to their Presentation Models. This worked quite fine until we started to remove Components and add them later. This is a problem, because the Presentation Model is prototype scoped and all data in the original presentation model is lost when it is replaced by a new presentation model.
Is there a possibility to prevent Autowireing at all addChild call when the component is already wired?
Example:
SomeUIComponent:
[Bindable]
[Autowired]
public var browserDialogPM:BrowserDialogPM;
Where the SomeUIComponent is used:
_content.addChild(someUIComponent);
--> Autowired ist done the first time in someUIComponent
_content.removeAllChildren();
_content.addChild(someUIComponent);
--> Autowired ist done the second time time in someUIComponent
that's a bug/issue indeed
Hey Andy,
I had this issue in the back of my mind when autowiring of stage components was implemented, I think I have some ideas on how to tackle this.
If you can, please add a ticket in JIRA with a feature request for this, I'll try and come up with a solution a.s.a.p.
You can add bug reports and feature requests if you follow this link:
http://jira.springframework.org/brow...ACTIONSCRIPTAS
cheers,
Roland