新曲!新曲!

by typester / at 2007-03-07T18:03:00 / life / Comment

ディスプレイ買うかなー

かなり前の EIZO 19インチ (FlexScan L465) 液晶をずっと使っているんだけど、最高に安物の DELL 液晶よりも視認性が悪い。並べて使ってるので気になりまりまくる。EIZO のほう、なんかぼんやりしてる。

しかも、L465 は DVI 接続、DELL は D-Sub アナログなのに!

古いからかなー。何年くらい使ってるんだろ。

by typester / at 2007-03-07T14:10:00 / life / Comment

AS3でのフルスクリーンモード

最小のサンプル。

package {
    import flash.display.Sprite;
    import flash.display.StageDisplayState;
    import flash.events.MouseEvent;
    import flash.events.FullScreenEvent;

    public class FullScreeeeeen extends Sprite {
        public function FullScreeeeeen() {
            stage.addEventListener(MouseEvent.CLICK, clickHandler);
            stage.addEventListener(FullScreenEvent.FULL_SCREEN, fullScreenHandler);
        }

        private function clickHandler(event:MouseEvent):void {
            if (stage.displayState == StageDisplayState.NORMAL) {
                stage.displayState = StageDisplayState.FULL_SCREEN;
            }
        }

        private function fullScreenHandler(event:FullScreenEvent):void {
            if (event.fullScreen) {
                trace("enter fullScreen mode");
            }
            else {
                trace("leave fullScreen mode");
            }
        }
    }
}

これだけ。あとは addParam("allowFullScreen", true) (SWFObject書式) すれば使える。

今の Flex2 SDK だったら追加のインストールファイルは何も必要ない模様。

by typester / at 2007-03-07T01:24:00 / flash · as3 / Comment