コンテンツ再生には最新のFlash Playerが必要です。You need the latest Adobe Flash Player to play the movie. Adobe - Flash Player Download

Source code of the above SWF

Fl040_StageConscious.as
package {
    import flash.display.Sprite;
    import flash.text.TextField;
    import flash.events.Event;
    import flash.display.StageScaleMode;
    
    [SWF(width="550",height="400")]
    public class Fl040_StageConscious extends Sprite{
        private var _textField:TextField;
        
        /**
         * Constructor
         */ 
        public function Fl040_StageConscious(){    
            stage.scaleMode = StageScaleMode.NO_SCALE;    
            stage.addEventListener(Event.RESIZE,onResize);
                
            _textField = new TextField();
            _textField.width = 550;
            _textField.height = 400;
            _textField.x = _textField.y = 100;
            this.addChild(_textField);
            _textField.appendText("[In Constructor]");
            this.showStatus(_textField);            
        }
        
        private function onResize(e:Event):void{
            _textField.appendText("[RESIZE]");
            this.showStatus(_textField);
        }
        
        private function showStatus(target:TextField):void{
            target.appendText(" stage.stageHeight: " + stage.stageWidth);
            target.appendText(" stage.stageHeight: " + stage.stageHeight + "\n");
        }
    }
}