tag:robotlegs.tenderapp.com,2009-10-18:/discussions/robotlegs-2/820-mediating-sparkmxml-applicationRobotlegs: Discussion 2018-10-18T16:35:46Ztag:robotlegs.tenderapp.com,2009-10-18:Comment/249226942013-02-14T09:36:39Z2013-02-14T09:36:39ZMediating spark/MXML Application<div><p>Hi Andreas,</p>
<p>I assumed that you were talking about your starling example on
github; I dl-ed it and created a MainMediator for the Main
view.</p>
<p>For the Main view to be mediated automatically, you need to
start the configuration on preinitialize (your preInit() method).
But in this case, you don’t have a reference to the stage
yet, so you can’t create your Starling.</p>
<p>If you run the configuration after addedToStage, you have to
manually mediate your Main view:</p>
<p>mediatorMap.map(Main).toMediator(MainMediator);<br>
mediatorMap.mediate(rootDisplayObject);</p>
<p>Does this answer your question?</p>
<p>Ondina</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/249226942013-02-14T15:35:01Z2013-02-14T15:35:01ZMediating spark/MXML Application<div><p>yes, it does! Thank you very much, Ondina!</p></div>andreas