//txt为舞台上的文本,用来显示舞台宽高变化,No_SCALE模式下,resize事件才有用啦!
import flash.events.Event;
this.stage.scaleMode = StageScaleMode.NO_SCALE;
txt.text = "舞台宽:"+this.stage.stageWidth+"\n"+"舞台高:"+this.stage.stageHeight;
this.stage.addEventListener(Event.RESIZE,dor);
function dor(e:Event):void
{
txt.text = "舞台宽:"+this.stage.stageWidth+"\n"+"舞台高:"+this.stage.stageHeight;
}