This content has been marked as final. Show 4 replies
It is possible that the PopUpManager was not compiled into the SWF (or some class that it uses). Only classes that are used are added to the SWF to keep the size of the SWF at a minimum.
When you build your main application and secondary applications, compile them with the -link-report=report.xml switch to regenerate a linkage report. You can examine that to see if PopUpManager has been included.
As a side note, you can use that linkage report from the main application to build a smaller swf for your on-the-fly MXML applications by compiling them with the linkage report:
This will make the SWF smaller by NOT including any components that are already in the main application. However, you won't be able to run these other apps independently any more.
When Flex 2.0.1 comes out (no date yet that I know of) take a look at <mx:Module> which would be a much better fit for your situtation. You would have very little retro-fitting to do, but it would provide better support for applications like yours.
Thanks for the reply. I compiled with the -load-externs option and i am able to get the list of stuff loaded and here is the snippet of my report where PopupManager been included...
<dep id="mx.events:CollectionEvent" />
<dep id="mx.events:ListEvent" />
<dep id="mx.managers:PopUpManager" />
<dep id="flash.events:KeyboardEvent" />
<dep id="Number" />
<dep id="Error" />
<dep id="mx.events:ScrollEvent" />
<dep id="mx.controls.dataGridClasses:DataGridListData" />
<dep id="flash.text:TextLineMetrics" />
<script name="D:\flex_sdk_2\frameworks\libs\rpc.swc(mx/messaging/MessageResponder)" mod="1150096864181" size="2788">
<def id="mx.messaging:MessageResponder" />
<pre id="flash.net:Responder" />
... some more lines...
And by this i can view that PopupManager been included. But still the problem exists.
And one more thing i want to know is how can i speed up the compilation process as i am creating swf files in client-server mode where after getting response xml i am creating mxml then swf and putting it in the server domain folder and sending the link of the generated file path as response to client.
Anysupport to speed-up this process as generation of mxml and compilation takes a long time...
And one more thing i want to know is if i use -load-extern=report.xml option and if i see that popupmanager is not been included in compilation then how can i include that.
Are you using SWFLoader?
var swf:SWFLoader = new SWFLoader();
swf.load( urlhere );
swf.width = #;
swf.height = #;
As far as compliation speed it works as fast as it can. There aren't any switches to improve its performance. Do the Flex apps you are generating follow a pattern - are the similar in some respect or are they very different? If they are similar you could have an application with much of the UI in place and then use the XML to dynamically create the elements in the Flex app itself. I'm not sure which would be faster given your circumstances.