Anyone know why the enterFullScreenDisplay method might be missing? It is listed in the documentation) but does not appear at compile time, thus throwing an error.
Don't believe me? Observe...
1061: Call to a possibly undefined method enterFullScreenDisplayState through a reference with static type fl.video:FLVPlayback.
So what is the embarrassingly obvious and simple solution to which I am blind? :(
Are you calling it on the class or an instance of the class?
That didn't come in until flash player 9 update 3.
a way to get around it while you're developing (which is a bit hacky), is to use:
player"enterFullScreenDisplay";
This may throw an error in your IDE, but will work for anyone using the correct version of the player in the browser.
Originally posted by: JLM Are you calling it on the class or an instance of the class?
Instance.
Originally posted by: lithium
player"enterFullScreenDisplay";
Ah yes. Will give that a shot.
Thanks, all!
My next question: Why might it be that my particular compiler does not recognize the method? More importantly, what can I do to fix it?
A few notes... - CS3 v9.0 on OSX 10.5.6 - enterFullScreenDisplayState is not present in FLVPlaybackAS3.swc > video > FLVPlayback - referencing the function name with a string throws a runtime error not only in the IDE (as promised) but in the browser as well (FP 10)
The plot thickens...
Following an upgrade to CS4, enterFullScreenDisplayState is now present in FLVPlaybackAS3.swc > video > FLVPlayback. HOWEVER... the method remains unavailable at compilation.
In case I'm missing anything, here are the relevant (albeit abbreviated) bits:
import fl.video.*;
public var flvPlayback:FLVPlayback;
public function VideoSexy() {
addEventListener(Event.ADDED_TO_STAGE, init);
}
private function init(e : Event = null) : void {
removeEventListener(Event.ADDED_TO_STAGE, init);
checkFlashVars()
setControls();
flvPlayback.registrationY = 0;
flvPlayback.align = VideoAlign.TOP;
flvPlayback.getVideoPlayer(flvPlayback.activeVideoPlayerIndex).smoothing = true;
**flvPlayback.enterFullScreenDisplayState();**
}
Yes, flvPlayback is onstage in the IDE.
Both FP9 and FP10 throw a reference error.
:(