movie does not start in full screen in flash video player

Posted by jodeci on Stack Overflow See other posts from Stack Overflow or by jodeci
Published on 2009-10-16T09:34:06Z Indexed on 2010/06/13 7:02 UTC
Read the original article Hit count: 296

Filed under:
|
|

We have this legacy code of a flash video player that functions well enough but still has some loose ends I need to tighten up. It can do the basic "switch to full screen and back to normal size" stunts, however with one exception.

On the first fresh load of the app, if I switch to full screen mode first, and then click to play the movie, the player would be in full screen, yet the movie itself would remain in it's original size.

//trigger
if (stage.displayState == StageDisplayState.NORMAL) {
  stage.addEventListener('fullScreen', procFullScreen);
  stage.scaleMode = StageScaleMode.NO_SCALE;
  stage.displayState = StageDisplayState.FULL_SCREEN;

  //mv:VideoDisplay
  mv.percentHeight = 100;
  mv.percentWidth = 100;
  mv.x = 0;
  mv.y = 0;
}

// event handler
if (event.fullScreen) {
  mv.smoothing = true;
  this.height = stage.height;
  this.width = stage.width;

  //videoCanvas:Canvas
  videoCanvas.height = Application.application.height;
  videoCanvas.width = Application.application.width;

  fullScreenViewStack.selectedIndex = 1;
}

The VideoDisplay object even returns the expected width/height, but the movie just plays in it's original size. If I switch screen sizes during movie playback, then the movie size will shrink or stretch as it should. I'm running out of ideas, any suggestions? Thanks in advance!

© Stack Overflow or respective owner

Related posts about flex

Related posts about flash