29-12-2009

Actionscript3 Stage align and stage scalemode AS3

The StageAlign class offers constant values that can be used for the Stage.align property.

The StageScaleMode class provides values for the Stage.scaleMode property.

http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002154.html

http://help.adobe.com/nl_NL/AS3LCR/Flash_10.0/flash/display/StageAlign.html

http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/display/StageAlign.html

Example:

package nl.hardcode
{
 
	import flash.display.MovieClip;
 
	import flash.display.StageAlign;
	import flash.display.StageScaleMode;
 
	public class Whatever extends MovieClip
	{	
		public function Whatever () {
			stage.align = StageAlign.TOP_LEFT;
			stage.scaleMode = StageScaleMode.NO_SCALE;
		}
	}
}
 

Comments:

Your comment:

»

 

[x]