Re: [flexcoders] Event before preinitialize

2010-06-10 Thread dorkie dork from dorktown
Thanks guys. I went with the preloader approach as that had the fastest
startup time. I'll provide numbers in the next message.

On Fri, Jun 4, 2010 at 10:43 AM, Anatole Tartakovsky 
anatole.tartakov...@gmail.com wrote:



 This is an old article of what you are trying to do :

 http://flexblog.faratasystems.com/2006/09/20/flex-developers-and-the-need-to-understand-flash
 There should be also article by Ted Patrick on the topic dated around the
 same time.
 Thank you
 Anatole



 On Fri, Jun 4, 2010 at 12:16 AM, Andriy Panas a.pa...@gmail.com wrote:

 Hi Judah,
 AFAIK, you have 2 approaches to execute the code before
 preinitialize event is fired.

 1) Mark you class with metadata [Mixin] and put the code in need into
 method

 public static function init(systemManager:ISystemManager):

 See HowTo create your developer ToolBox with Mixins blog article

 http://www.rialvalue.com/blog/2010/05/21/howto-create-your-developer-toolbox-with-mixins/

 2) Via custom preloader class you can execute the code before
 SystemManager.intialize() method executes,

 See How I (sort of) modified Flex’s SystemManager.initialize() method

 http://www.visible-form.com/blog/how-i-sort-of-modified-flexs-systemmanagerinitialize-method/

 --
 Best regards,
 Andriy Panas



 On 4 June 2010 06:57, dorkie dork from dorktown
 dorkiedorkfromdorkt...@gmail.com wrote:
 
 
 
  That's what I'd like to do. So I added an event listener to the
 application preinitialized event like so:
 
  s:Application preinitialize=myHandler() /
 
  the problem is, in my application it takes a while to get to that event.
 so that's why I'm trying to find another event that happens sooner than
 that. it would be great to have systemManager, fontManager, resourceManager
 and styleManager creationComplete events so I can see what's taking so long
 in addition to redirecting if I need to.
 
  JP
 
  On Thu, Jun 3, 2010 at 10:02 PM, Kerry Thompson 
 al...@cyberiantiger.biz wrote:
 
 
 
  it's taking a couple of seconds to reach the preinitialize event.
  according to this slideshow
 http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide
 24, 25 etc
  there are a couple things going on that i don't need early on. so i'd
 like to check the contents of a shared object or session variable early on
 and redirect to a much lighter login page if i need to.
 
 
  It doesn't take long to check the contents of a shared object. Why not
 just do that before you intialize the object, and let it know whether to do
 the lighter load?
 
  Cordially,
 
  Kerry Thompson
 
 


 

 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Alternative FAQ location:
 https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
 Links




  



Re: [flexcoders] Event before preinitialize

2010-06-10 Thread dorkie dork from dorktown
Gordon or Alex,

Here are the numbers. Excuse the length. This is in ms from the launch of
the application using getTimer().

Preloader constructor 314
Preloader initialize 316
Preloader progress event 388
[SWF] /app-debug/home.swf - 3,520,823 bytes after decompression
progress event 626
progress event 663
progress event 692
progress event 720
[SWF] /app-debug/home.swf/[[DYNAMIC]]/1 - 648,239 bytes after decompression
progress event 882
[SWF] /app-debug/home.swf/[[DYNAMIC]]/2 - 370,463 bytes after decompression
progress event 1138
progress event 1158
[SWF] /app-debug/home.swf/[[DYNAMIC]]/3 - 2,292,131 bytes after
decompression
progress event 1646
progress event 1695
progress event 1713
[SWF] /app-debug/home.swf/[[DYNAMIC]]/4 - 1,429,050 bytes after
decompression
progress event 2050
[SWF] /app-debug/home.swf/[[DYNAMIC]]/5 - 323,414 bytes after decompression
progress event 2266
progress event 2292
[SWF] /ripple-debug/home.swf/[[DYNAMIC]]/6 - 441,686 bytes after
decompression
progress event 2446
progress event 2468
progress event 2900

Application Preinitialize event 3691

preloader? complete event 3769

initProgress event 3770
initProgress event 4558

Preloader create children event 4560

initProgress event 4805
initProgress event 4932
initProgress event 4951
initProgress event 4961
initProgress event 4968
initComplete event 4976


The application preinitialize starts at 3691. So it would be roughly that
long before I could redirect the visitor if I needed to. In the preloader
initialize I can redirect the user or add something to the display list at
316ms. So that event works for me.

What I don't understand from this is it takes 4 seconds before the flex
preloader appears. :( Why does it take so long? And more importantly how do
I get the Flex preloader to show up (and work) quicker?

Notice that the preloader create children method starts at 4560. So the user
doesn't see anything but a blank screen until then.

JP


On Thu, Jun 3, 2010 at 7:12 PM, Gordon Smith gosm...@adobe.com wrote:



  I don't think so. How early do you need it? Why isn't preinitialize early
 enough?



 - Gordon



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *dorkie dork from dorktown
 *Sent:* Thursday, June 03, 2010 12:59 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* [flexcoders] Event before preinitialize





 Is there an event before application preinitialize that I can listen
 for in the application?

 JP

   



Re: [flexcoders] Event before preinitialize

2010-06-10 Thread Alex Harui
What does the URL look like?  If there’s a “#” in it, a FlashPlayer bug will 
delay until the entire SWF downloads.

Your main SWF is 3.5Mb even when using RSLs.  Is all that needed for the first 
screen?  Modules will offload some of that to later and speed everything up.


On 6/10/10 6:01 PM, dorkiedorkfromdorkt...@gmail.com 
dorkiedorkfromdorkt...@gmail.com wrote:






Gordon or Alex,

Here are the numbers. Excuse the length. This is in ms from the launch of the 
application using getTimer().

Preloader constructor 314
Preloader initialize 316
Preloader progress event 388
[SWF] /app-debug/home.swf - 3,520,823 bytes after decompression
progress event 626
progress event 663
progress event 692
progress event 720
[SWF] /app-debug/home.swf/[[DYNAMIC]]/1 - 648,239 bytes after decompression
progress event 882
[SWF] /app-debug/home.swf/[[DYNAMIC]]/2 - 370,463 bytes after decompression
progress event 1138
progress event 1158
[SWF] /app-debug/home.swf/[[DYNAMIC]]/3 - 2,292,131 bytes after decompression
progress event 1646
progress event 1695
progress event 1713
[SWF] /app-debug/home.swf/[[DYNAMIC]]/4 - 1,429,050 bytes after decompression
progress event 2050
[SWF] /app-debug/home.swf/[[DYNAMIC]]/5 - 323,414 bytes after decompression
progress event 2266
progress event 2292
[SWF] /ripple-debug/home.swf/[[DYNAMIC]]/6 - 441,686 bytes after decompression
progress event 2446
progress event 2468
progress event 2900

Application Preinitialize event 3691

preloader? complete event 3769

initProgress event 3770
initProgress event 4558

Preloader create children event 4560

initProgress event 4805
initProgress event 4932
initProgress event 4951
initProgress event 4961
initProgress event 4968
initComplete event 4976


The application preinitialize starts at 3691. So it would be roughly that long 
before I could redirect the visitor if I needed to. In the preloader initialize 
I can redirect the user or add something to the display list at 316ms. So that 
event works for me.

What I don't understand from this is it takes 4 seconds before  the flex 
preloader appears. :( Why does it take so long? And more importantly how do I 
get the Flex preloader to show up (and work) quicker?

Notice that the preloader create children method starts at 4560. So the user 
doesn't see anything but a blank screen until then.

JP


On Thu, Jun 3, 2010 at 7:12 PM, Gordon Smith gosm...@adobe.com wrote:





I don't think so. How early do you need it? Why isn't preinitialize early 
enough?

- Gordon


From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of dorkie dork from dorktown
Sent: Thursday, June 03, 2010 12:59 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Event before preinitialize




Is there an event before application preinitialize that I can listen
for in the application?

JP










--
Alex Harui
Flex SDK Team
Adobe System, Inc.
http://blogs.adobe.com/aharui


Re: [flexcoders] Event before preinitialize

2010-06-04 Thread Anatole Tartakovsky
This is an old article of what you are trying to do :
http://flexblog.faratasystems.com/2006/09/20/flex-developers-and-the-need-to-understand-flash
There should be also article by Ted Patrick on the topic dated around the
same time.
Thank you
Anatole



On Fri, Jun 4, 2010 at 12:16 AM, Andriy Panas a.pa...@gmail.com wrote:

 Hi Judah,
 AFAIK, you have 2 approaches to execute the code before
 preinitialize event is fired.

 1) Mark you class with metadata [Mixin] and put the code in need into
 method

 public static function init(systemManager:ISystemManager):

 See HowTo create your developer ToolBox with Mixins blog article

 http://www.rialvalue.com/blog/2010/05/21/howto-create-your-developer-toolbox-with-mixins/

 2) Via custom preloader class you can execute the code before
 SystemManager.intialize() method executes,

 See How I (sort of) modified Flex’s SystemManager.initialize() method

 http://www.visible-form.com/blog/how-i-sort-of-modified-flexs-systemmanagerinitialize-method/

 --
 Best regards,
 Andriy Panas



 On 4 June 2010 06:57, dorkie dork from dorktown
 dorkiedorkfromdorkt...@gmail.com wrote:
 
 
 
  That's what I'd like to do. So I added an event listener to the
 application preinitialized event like so:
 
  s:Application preinitialize=myHandler() /
 
  the problem is, in my application it takes a while to get to that event.
 so that's why I'm trying to find another event that happens sooner than
 that. it would be great to have systemManager, fontManager, resourceManager
 and styleManager creationComplete events so I can see what's taking so long
 in addition to redirecting if I need to.
 
  JP
 
  On Thu, Jun 3, 2010 at 10:02 PM, Kerry Thompson al...@cyberiantiger.biz
 wrote:
 
 
 
  it's taking a couple of seconds to reach the preinitialize event.
  according to this slideshow
 http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide
 24, 25 etc
  there are a couple things going on that i don't need early on. so i'd
 like to check the contents of a shared object or session variable early on
 and redirect to a much lighter login page if i need to.
 
 
  It doesn't take long to check the contents of a shared object. Why not
 just do that before you intialize the object, and let it know whether to do
 the lighter load?
 
  Cordially,
 
  Kerry Thompson
 
 


 

 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Alternative FAQ location:
 https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
 Search Archives:
 http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
 Links






[flexcoders] Event before preinitialize

2010-06-03 Thread dorkie dork from dorktown
Is there an event before application preinitialize that I can listen
for in the application?

JP


RE: [flexcoders] Event before preinitialize

2010-06-03 Thread Gordon Smith
I don't think so. How early do you need it? Why isn't preinitialize early 
enough?

- Gordon

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of dorkie dork from dorktown
Sent: Thursday, June 03, 2010 12:59 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Event before preinitialize



Is there an event before application preinitialize that I can listen
for in the application?

JP



Re: [flexcoders] Event before preinitialize

2010-06-03 Thread dorkie dork from dorktown
 it's taking a couple of seconds to reach the preinitialize event.
according to this slideshow
http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide 24,
25 etc
there are a couple things going on that i don't need early on. so i'd like
to check the contents of a shared object or session variable early on and
redirect to a much lighter login page if i need to.

On Thu, Jun 3, 2010 at 7:12 PM, Gordon Smith gosm...@adobe.com wrote:



  I don't think so. How early do you need it? Why isn't preinitialize early
 enough?



 - Gordon



 *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
 Behalf Of *dorkie dork from dorktown
 *Sent:* Thursday, June 03, 2010 12:59 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* [flexcoders] Event before preinitialize





 Is there an event before application preinitialize that I can listen
 for in the application?

 JP

   



Re: [flexcoders] Event before preinitialize

2010-06-03 Thread Kerry Thompson

 it's taking a couple of seconds to reach the preinitialize event.
 according to this slideshow
 http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide
 24, 25 etc
 there are a couple things going on that i don't need early on. so i'd like
 to check the contents of a shared object or session variable early on and
 redirect to a much lighter login page if i need to.


It doesn't take long to check the contents of a shared object. Why not just
do that before you intialize the object, and let it know whether to do the
lighter load?

Cordially,

Kerry Thompson


Re: [flexcoders] Event before preinitialize

2010-06-03 Thread dorkie dork from dorktown
That's what I'd like to do. So I added an event listener to the application
preinitialized event like so:

s:Application preinitialize=myHandler() /

the problem is, in my application it takes a while to get to that event. so
that's why I'm trying to find another event that happens sooner than that.
it would be great to have systemManager, fontManager, resourceManager and
styleManager creationComplete events so I can see what's taking so long in
addition to redirecting if I need to.

JP

On Thu, Jun 3, 2010 at 10:02 PM, Kerry Thompson al...@cyberiantiger.bizwrote:



  it's taking a couple of seconds to reach the preinitialize event.
 according to this slideshow
 http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide
 24, 25 etc
 there are a couple things going on that i don't need early on. so i'd like
 to check the contents of a shared object or session variable early on and
 redirect to a much lighter login page if i need to.


 It doesn't take long to check the contents of a shared object. Why not just
 do that before you intialize the object, and let it know whether to do the
 lighter load?

 Cordially,

 Kerry Thompson
  



Re: [flexcoders] Event before preinitialize

2010-06-03 Thread Andriy Panas
Hi Judah,
AFAIK, you have 2 approaches to execute the code before
preinitialize event is fired.

1) Mark you class with metadata [Mixin] and put the code in need into method

public static function init(systemManager:ISystemManager):

See HowTo create your developer ToolBox with Mixins blog article
http://www.rialvalue.com/blog/2010/05/21/howto-create-your-developer-toolbox-with-mixins/

2) Via custom preloader class you can execute the code before
SystemManager.intialize() method executes,

See How I (sort of) modified Flex’s SystemManager.initialize() method
http://www.visible-form.com/blog/how-i-sort-of-modified-flexs-systemmanagerinitialize-method/

--
Best regards,
Andriy Panas



On 4 June 2010 06:57, dorkie dork from dorktown
dorkiedorkfromdorkt...@gmail.com wrote:



 That's what I'd like to do. So I added an event listener to the application 
 preinitialized event like so:

 s:Application preinitialize=myHandler() /

 the problem is, in my application it takes a while to get to that event. so 
 that's why I'm trying to find another event that happens sooner than that. it 
 would be great to have systemManager, fontManager, resourceManager and 
 styleManager creationComplete events so I can see what's taking so long in 
 addition to redirecting if I need to.

 JP

 On Thu, Jun 3, 2010 at 10:02 PM, Kerry Thompson al...@cyberiantiger.biz 
 wrote:



 it's taking a couple of seconds to reach the preinitialize event.
 according to this slideshow 
 http://www.slideshare.net/michael.labriola/dense-and-hot-360-flex slide 24, 
 25 etc
 there are a couple things going on that i don't need early on. so i'd like 
 to check the contents of a shared object or session variable early on and 
 redirect to a much lighter login page if i need to.


 It doesn't take long to check the contents of a shared object. Why not just 
 do that before you intialize the object, and let it know whether to do the 
 lighter load?

 Cordially,

 Kerry Thompson

 




--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location: 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
flexcoders-dig...@yahoogroups.com 
flexcoders-fullfeatu...@yahoogroups.com

* To unsubscribe from this group, send an email to:
flexcoders-unsubscr...@yahoogroups.com

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/