I've run into a little problem and I can't seem to find a solution.
After many hours of programming I have made a little Tetris game,
which works more or less perfectly. Then I wanted to add some
controls with GLUI. The problem is when I change the difficulty, for
example, the main window loses focus (or rather the game portion of
the window) and I can no longer play the game.
I'm using GLUI_Master.set_glutKeyboardFunc(key) to register my
keyboard function but the control window still steals focus when I
click on it, and clicking on the graphics portion doesn't return
focus. If I could make the main window focus SOMEHOW, either by
calling a function every time I change a control, or clicking on the
graphics portion again... anything would help.
screenshot: http://www.sfu.ca/~mnb2/tetris.gif
Thanks for any help.
|
|
0
|
|
|
|
Reply
|
mnbayazit (245)
|
10/2/2007 8:16:18 AM |
|