views:

52

answers:

1

Hello.

I'm trying to resize a flash game inside a VGroup, no matter what configuration i try to set, some of my flash games are clipped out. i see only 80% of the actual flash screen.

this is my code:

<s:VGroup id="gameVGroup" clipAndEnableScrolling="true" height="480" maxHeight="480" width="540" maxWidth="540">
        <mx:SWFLoader id="swfGameLoader" loadForCompatibility="true" scaleContent="true" maintainAspectRatio="true" width="100%" height="100%" maxWidth="540" maxHeight="480" />
    </s:VGroup>     

any ideas?

update

i still want to maintain aspect ratio. so if the game is wider or taller then my application window, i want it to be resized properly.

A: 
maintainAspectRatio="false"
Eugene
i would prefer to maintain aspect ratio.
ufk
then add Enter_Frame event handler and check the sizes of container and content of container manually.
Eugene
ok i'll try that, thanks
ufk
don't forget to share your solution, btw instead of enterFrame event you could call listen to RESIZE and creationComplete events, it will optimize memory usage.
Eugene