Posted by: edsyrett | 27 February 2009

Full Screen…but not quite

Right now I’m writing a Flex app that manages and runs online exams.  Currently, the part of the app that shows the exam ready for the candidate to enter answers is part of the same application that allows a user to manage the details of the exams etc.  

This is actually what the specification required.  It might be the case that our candidates take the exam by ticking boxes on a piece of paper and then an admin enters the results later.  But I think a candidate should be able to enter sit in front of a pc running the app and be able to take the exam online.  Whilst taking the exam, the candidate should be prevented from accessing any other part of the app.

So I started thinking about maximising the exam.  Sure enough, Flash allows us to show an app full screen.  Full details of how to do this appear in the livedocs here.

But about half way down there’s a paragraph that’s a real killer…

All keyboard-related ActionScript, such as keyboard events and text entry in TextField instances, is disabled in full-screen mode. The exception is the keyboard shortcuts that close full-screen mode.

In other words, you can’t type into TextInput fields when your app is full screen.  Note that this only applies to apps that run in Flash Player – if you’re writing for AIR, then StageDisplayState.FULL_SCREEN_INTERACTIVE is available and everything works as normal.

So I had to settle for making a particular container full screen within the application stage, i.e the browser.  It turns out that this isn’t too difficult, as all you need to do is remove the display object that you want to make full screen from its parent and add it as a child of the System Manager.

That worked fine for me, but the test app I did removed a container from within a popup TitleWindow.  I found that although the container was now a child of the the top-level System Manager, the popup (which used to be its parent) still showed over the top.  So I also had to hide all popups whilst my container is full screen.

My test app is here.  To quote one of my Flex Heroes, Alex Harui, “the usual caveats apply”…



  1. Just passing by.Btw, your website have great content!

    Making Money $150 An Hour

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s


%d bloggers like this: