tag:robotlegs.tenderapp.com,2009-10-18:/discussions/problems/1727-early-context-initialization-to-let-the-bootstrap-take-place-while-preloader-is-visibleRobotlegs: Discussion 2013-06-10T11:39:43Ztag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-05-24T16:43:16Z2013-05-24T16:43:16ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>I don't get it. If you overrode the initCompleteHandler, isn't
the preloader shown automatically while the context does the
autostartup?</p></div>creynderstag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-05-26T08:42:19Z2013-05-26T08:42:19ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>No, the context doesn't autostartup. I have defined it in
fx:Declarations section. Should I define it on some flex
application event ?</p></div>Chetan Sachdevtag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-05-26T17:48:02Z2013-05-26T17:48:02ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>Could you post the context initialization code? Normally it
autostarts.</p></div>creynderstag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-05-27T08:37:26Z2013-05-27T08:37:26ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>In my main application, I have added:<br>
<code><fx:Declarations> <!-- Place non-visual elements
(e.g., services, value objects) here -->
<mvcs:ApplicationContext contextView="{this}"/>
</fx:Declarations></code></p>
<p>and ApplicationContext looks like below:<br>
'</p>
<p>public class ApplicationContext extends Context<br>
{ public function
ApplicationContext(contextView:DisplayObjectContainer=null,
autoStartup:Boolean=true) { super(contextView, autoStartup); }</p>
<pre>
<code> override public function startup():void
{
commandMap.mapEvent(InitConfigureEvent.CONFIGURE,InitConfigurationCommand);
.....
.....
dispatchEvent(new InitConfigureEvent());
}
}'</code>
</pre></div>Chetan Sachdevtag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-05-29T05:52:31Z2013-05-29T05:52:31ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>Hi, not sure whether it's <em>the</em> cause, but shouldn't it
be</p>
<pre>
<code>dispatchEvent(new InitConfigureEvent(InitConfigureEvent.CONFIGURE));</code>
</pre>
<p>?</p></div>creynderstag:robotlegs.tenderapp.com,2009-10-18:Comment/269935332013-06-10T11:39:39Z2013-06-10T11:39:39ZEarly context initialization to let the bootstrap take place while preloader is visible<div><p>Hi Chetan,<br>
I'm assuming this is resolved. Feel free to reopen this discussion
in case you have more questions or you need further assistance with
this issue.</p></div>Ondina D.F.