Joined: May 25, 2003 Posts: 4752 Location: Santa Barbara, CA
Posted: Fri Oct 31, 2003 10:08 am Post subject: Full screen mode presentations and Panther
I got a chance to use NeoJ on Panther during OSXCON, and after I couldn't compile the weekend before due to problems with the main OOo CVS server (missing modules again...) I found a nifty trick.
Panther includes a nice new system UI mode for doing kiosk applications. It's mode "4", kUIModeAllSuppressed (check the MacApplication.h header). When set, it hides the menubar and the dock when the application is in the foreground. If the mouse moves into the area where the menubar or dock would be, they're shown. It's like having dock hiding turned on for both the dock and the menubar.
You can turn this on for the entire app by editing the bundle's Info.plist. Add a new key named "LSUIPresentationMode", value type Number, set to 4. Voila.
This mode is useful since it's not so invasive that I minded having it always turned on. The main menubar is mostly useless for NeoJ, but you can still mouse into it to look at battery life, clock, etc. The dock functions just as if dock hiding is on...apps that use bouncing notificatins and the like will still bounce in from whatever edge of the screen they're on.
But the menubar curse is still there, somewhat...I haven't looked at the code to see how NeoJ's getting screen bounds, but I'm assuming there are more VM bugs here. The screen height is off by the menubar height, so a small band will be left visible at the bottom of the screen equal to the menubar height (but with no contents). Sleazy workaround is to make your desktop background black or a solid color instead of whatever would normally be there.
Yet even more interesting...the VM apparently doesn't enjoy life when you start changing screen resolutions on the fly (which I did a lot when disconnecting/reconnecting to projectors). We may not be able to fix that in the VM, but definitely should handle display reconfiguration notices in plain old neo when the time comes.
I finally got around to implementing code that calls SetSystemUIMode() that you pointed me to in SalFrame::StartPresentation(). It took a little tweaking to get presentation window to fill the whole screen when the system menubar is hidden, but I finally got it to work.
With my changes to the code (I expect to put a patch out with my printing enhancements later this week), the menubar and dock are hidden and disabled when you are in presentation mode. Both reappear when you end the presentation.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum