2008. 9. 1. 11:06

[flex3] 전체 화면 보여주기 / Displaying full-screen windows

Reference : http://livedocs.adobe.com/flex/3/html/WorkingWithWindows_6.html#1032227

Stage의 displayState 속성을 StageDisplayState.FULL_SCREEN_INTERACTIVE 으로 지정하면 창을 전체 화면 모드로 전환시킵니다. 이 모드에서 키보드를 입력은 가능합니다. (In SWF content running in a browser, keyboard input is not permitted). 전체 화면 모드를 끝낼 때는 Escape 키를 누르면 됩니다.

예를 들어 아래의 Flex 코드는 간단한 전체 화면 터미널을 설정하는 간단한 AIR 어플리케이션을 정의합니다:

<?xml version="1.0" encoding="utf-8"?> <mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical" applicationComplete="init()" backgroundColor="0x003030" focusRect="false"> <mx:Script> <![CDATA[ private function init():void { stage.displayState = StageDisplayState.FULL_SCREEN_INTERACTIVE; focusManager.setFocus(terminal); terminal.text = "Welcome to the dumb terminal app. Press the ESC key to exit..\n"; terminal.selectionBeginIndex = terminal.text.length; terminal.selectionEndIndex = terminal.text.length; } ]]> </mx:Script> <mx:TextArea id="terminal" height="100%" width="100%" scroll="false" backgroundColor="0x003030" color="0xCCFF00" fontFamily="Lucida Console" fontSize="44"/> </mx:WindowedApplication>