Hi Renaun,

Insert the following into your loaded mxml applications (the ones
set as the content for your Loader control), and they will properly
resize.

Regards,
Doug

<mx:Script>
    <![CDATA[
        function getPreferredHeight() {
            return _parent? _parent.layoutHeight :
super.getPreferredHeight();
        }

        function getPreferredWidth() {
            return _parent? _parent.layoutWidth :
super.getPreferredWidth();
        }
    ]]>
</mx:Script>



--- In [email protected], "Renaun Erickson" <[EMAIL PROTECTED]>
wrote:
>
> I have read and re-read all the posts on breaking up a big
application
> into smaller chunks either using the Loader method or createChild.
>
> createChild works well to delay creation of objects but the
actually
> SWF size is not smaller as the classes are compiled into the
> application.  The Loader loads stuff on runtime but you get longer
> load times because of overlapping of common classes (each loaded
SWF
> is a Flex app with the main component being the Application class).
>
> My question I have is in regards to the Loader and loading other
> <mx:Application> flex SWFs.  When I try to do this, I can not get
the
> loader swf's to stay dyanmic 100% widht and height.  I want the
loaded
> application SWF to fill up the container it was loaded in.
>
> It has to do with something when it reaches 500 width and 375
height,
> some defaults in the Application class.  I found some methods of
> hacking the width and height to work somewhat reasonably, but in
the
> end it doesn't seem right.
>
> I know the Flex Exampler Explorer is a good example of loading
> different Application SWF into a container but none of them do 100%
> width/height.
>
> First, do people really use Loader to load multiple Flex
> mini-applications? 
>
> and if so how do you address the 100% width/height issue?
>






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com




SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




Reply via email to