Reputation: 14290
I was wondering if there are anyways to get the fixed size swf file when I build my AS3 only project in Flex environment. I can't use scaleMode="noScale" since my swf is very small. I don't want it expand it to full browser winder either. Are there anyways to do it? Thanks for the help!
Upvotes: 0
Views: 962
Reputation: 881
Use metadata above the main class declaration
[SWF(width="400", height="125")]
public class MyAS3Project extends Sprite
Upvotes: 1
Reputation: 4179
Your Application is sort of like a Canvas inside of the flash player. Thus, you can give it a fixed size (with the width and height attributes), but that will just reduce its size inside the flash player. I don't think you can mess with this in pure AS3 - you'd need to change the underlying HTML (although, you may be able to do this with ExternalInterface, which allows you to call javascript methods on the HTML page...).
Upvotes: 1