skilleddesigner
asked on
when i do fullscreen flash why does the flash movie align in the left side of the browser?
Hi
I am using this code to do fullscreen flash but whenever its fullscreen the flash align in the left side of the browser
i really dont get it why??
I am using this code to do fullscreen flash but whenever its fullscreen the flash align in the left side of the browser
i really dont get it why??
//Don't scale the movie when the stage size changes
Stage.scaleMode="noScale";
//Align the stage to the top left
Stage.align = "TL";
//Function to toggle between fullscreen and normal size
//the toggle fullscreen button calls this function when pressed
function toggleFullScreen(){
//if normal size, go to fullscreen, else go to normal size
if(Stage["displayState"]=="normal"){
Stage["displayState"]="fullScreen";
}else{
Stage["displayState"]="normal";
}
}
//Create a listener for each time the Stage is resized
var resizeListener:Object = new Object();
//Called each time the stage is resized
resizeListener.onResize = function () {
//Move the button to the center of the screen
toggleFullScreenButton._x=Stage.width/2;
toggleFullScreenButton._y=Stage.height/2;
}
//Add the listener to Stage
Stage.addListener(resizeListener);
This shows you what the alignment variables mean:
http://www.adobe.com/livedocs/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002690.html
http://www.adobe.com/livedocs/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002690.html
ASKER
How can i made it totally center align??
ASKER
How can i make it vertically and horizontally center align??
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
i tried removing the line or i did tried putting "C"
but both the way it align bottom left of the screen
but both the way it align bottom left of the screen
ASKER
thanks
CyanBlue