PDA

View Full Version : FullscreenEvent not firing?



cptnemo
January 24th, 2008, 06:56 AM
Hey all,

I have the following:
A document class, extending from a custom class, extending from MovieClip. In my document class, I assign a handler to the FullScreenEvent like so:


addEventListener(FullScreenEvent.FULL_SCREEN, function(e) { toggle_fullscreen(); });

Also, I've set up a SimpleButton to call that same function, toggle_fullscreen, when clicked.

Here's the catch:
When I click the button, my app goes fullscreen. When I press Esc, the app goes back to normal but the FullScreenEvent doesn't get fired, so I can't catch it to re-align the elements on my stage.
I've also tried to add the event listener to the stage object of my document class, but that doesn't work either.

Any ideas?

cptnemo
January 28th, 2008, 04:37 AM
Sorry for bumping, but this looks like a simple question to me.
I just can't get the Event to fire though.
Please help me out, guys :).

mpick
February 13th, 2008, 06:54 PM
I'm having the same problem - additionally, FullScreenEvent does not seem to fire when a full screen video finishes and the player automatically exits full screen.

Any insight into this would be appreciated.

dail
February 25th, 2008, 06:36 PM
add stage.addEventListener rather than addEventListener for that event. Then it should work.

gilbejam
October 26th, 2010, 07:32 PM
adding the event listener to the stage worked for me too.