0 Replies Latest reply on Aug 27, 2010 12:42 AM by YuriGertsen

    Flex 4. s:VideoPlayer - Double Click and FullScreen

    YuriGertsen

      Double-click to the viewing area, I'd like to move to full-screen mode. The how of it.

       

      Don`t work MouseEvent.DOUBLE_CLICK and doubleClick="" in Spark!!!! (((

       

      private function init():void {

      videoDisplay.addEventListener(MouseEvent.DOUBLE_CLICK, display_doubleClick);

      }

       

      private function display_doubleClick(evt:MouseEvent):void { 

      switch(stage.displayState) {

      case "normal":

      stage.displayState = "fullScreen";

      break;

      case "fullScreen":

      default:

      stage.displayState = "normal";   

      break;

      }

      }

       

      <s:VideoDisplay id="videoDisplay" bottom="65" left="0" right="0" top="1"  doubleClickEnabled="true"

                                  bottom.fullScreenStates="0" left.fullScreenStates="0"

                                  right.fullScreenStates="0" top.fullScreenStates="0"

      click="play()" doubleClick="display_doubleClick(event)" />

       

      Message was edited by: YuriGertsen