HaikuDepot: notify work status from main window
[haiku.git] / src / libs / glut / glutState.h
blob2de114f724af1f2147e51a89ae016acb4c94cfde
1 /***********************************************************
2 * Copyright (C) 1997, Be Inc. Copyright (C) 1999, Jake Hamby.
4 * This program is freely distributable without licensing fees
5 * and is provided without guarantee or warrantee expressed or
6 * implied. This program is -not- in the public domain.
9 * FILE: glutState.h
11 * DESCRIPTION: the global state for GLUT
12 * (takes the place of glutint.h in the C version)
13 ***********************************************************/
15 /***********************************************************
16 * Headers
17 ***********************************************************/
18 #include <GL/glut.h>
19 #include <Application.h>
21 #include "glutWindow.h"
22 #include "glutMenu.h"
23 #include "glutGameMode.h"
25 /***********************************************************
26 * CLASS: GlutState
28 * DESCRIPTION: all the global state variables
29 ***********************************************************/
30 struct GlutState {
31 BApplication *display;
32 thread_id appthread;
34 int initX, initY; // initial window position
35 int initWidth, initHeight; // initial window size
36 unsigned int displayMode; // initial display mode
37 char *displayString; // verbose display mode
39 GlutWindow *currentWindow; // current window
40 GlutMenu *currentMenu; // current menu
42 GlutWindow **windowList; // array of pointers to windows
43 int windowListSize; // size of window list
45 GLUTidleCB idle; // idle callback
46 GLUTmenuStatusCB menuStatus; // menu status callback
47 int modifierKeys; // only valid during keyboard callback
48 int keyRepeatMode; // global repeat
50 GlutGameMode gameMode;
52 bool debug; // call glGetError
53 bool quitAll; // quit
55 GlutState() {
56 display = 0;
57 appthread = 0;
58 initX = initY = -1;
59 initWidth = initHeight = 300;
60 displayMode = GLUT_RGB | GLUT_SINGLE | GLUT_DEPTH;
61 displayString = 0;
62 currentWindow = NULL;
63 currentMenu = NULL;
64 windowList = NULL;
65 windowListSize = 0;
66 idle = 0;
67 menuStatus = 0;
68 modifierKeys = ~0;
69 keyRepeatMode = GLUT_KEY_REPEAT_DEFAULT;
70 debug = quitAll = false;
74 /***********************************************************
75 * Global variable (declared in glutInit.cpp)
76 ***********************************************************/
77 extern GlutState gState;