PDA

View Full Version : Detecting Loss/Gain of Focus



Radly
09-30-2010, 03:19 PM
I'm porting a Windows-based app to run on Mac/Linux/Windows with the same codebase and that seems to indicate GLUT as the prime candidate for the window manager. One of the features of the original app is to automatically pause when focus is lost and restart when focus is regained. I can't find a GLUT feature that supports that, so I have two questions:

1. Am I just missing it and it's in there somewhere?
2. Is there another portable scheme for detecting focus loss and gain?

Any suggestions appreciated. The project is near completion (for Mac OSX and Windows; not yet tested on Linux) and this is one of the final touches.

Clancy101
09-30-2010, 11:37 PM
I don't think so in glut, but you can switch to SDL for that, and that works with macs / linux / windows--that is, if it isn't too late.