I’ve made a flash application using actionscript 3,
I wanted this application size to be dynamic,
To be able to embed it in any size and let it adjust itself accordingly.
I managed to accomplish this, theres a problem though:
The original width of the application is 700 pixels.
I’m embedding the flash in a smaller size, (400 for example)
going to full screen, and when I exit, the application sets itself back to being 700 pixels wide, and isn’t adjusting itself to the 400px width of the actual embedding area..
I hope that I made myself clear enough,
Any help would be appreciated,
Thanks in advance!
EDIT:
That’s the code that toggles fullscreen modes in my application:
function fullScreenToggle(e:MouseEvent):void {
if(stage.displayState == "fullScreen"){
stage.displayState=StageDisplayState.NORMAL;
} else {
stage.scaleMode = StageScaleMode.NO_SCALE;
stage.align = StageAlign.TOP_LEFT;
stage.displayState=StageDisplayState.FULL_SCREEN;
}
}
stage.addEventListener(Event.RESIZE, onResizeDo);
Well I figured it out myself, What I did was simply put this line of code, to be run after the user exits the fullscreen mode. stage.scaleMode = StageScaleMode.SHOW_ALL;