Kiosk-fullscreen unhides menu's

One of the applications I’ve been developing requires it to be run fullscreen (being used on a large tangible/multi-touch interface) and so I’ve been using kiosk mode to take care of setting up the window fullscreen. Adding my main Component (contentComponent) to the desktop, and then calling Desktop::getInstance().setKioskModeComponent(contentComponent, false) works great, and hides the window title bar, the OS X dock, etc.

…However I noticed that if I switch over to another app (using OSX’s Expose features or Command-Tab), when I switch back to my app, the title-bar and OS X dock appear. Any ideas on fixing this or is there another way I should be doing fullscreen?

Well yes - when you switch apps, it comes out of kiosk mode, that’s how things work on the mac. The demo app has a kiosk option on its menu, which shows how it works. If you want it to go back to kiosk mode when they focus on your app again, you’d probably need to do so when your window gets focused.

Thanks Jules, thought it might be something like that. It was pretty easy to get going and for anyone stumbling here in the future, just override focusGained in your main component (making sure it wants keyboard focus) that gets displayed on your Window and re-enter kioskmode whenever that method gets called. Originally I was trying to override activeWindowStatusChanged in my main window (DocumentWindow) but couldn’t get that working-- I’ll keep it as is for now unless there is a more appropriate callback to use? Thanks again.