]> icculus.org git repositories - divverent/darkplaces.git/blob - cl_gecko.h
made r_shownormals value control the length of the vectors shown, rather
[divverent/darkplaces.git] / cl_gecko.h
1 // Andreas Kirsch 07\r
2 \r
3 #ifdef SUPPORT_GECKO\r
4 \r
5 #ifndef CL_GECKO_H\r
6 #define CL_GECKO_H\r
7 \r
8 #include "cl_dyntexture.h"\r
9 \r
10 #define DEFAULT_GECKO_WIDTH     512\r
11 #define DEFAULT_GECKO_HEIGHT    DEFAULT_GECKO_WIDTH\r
12 \r
13 #define CLGECKOPREFIX                   CLDYNTEXTUREPREFIX "gecko/"\r
14 #define MAX_GECKO_INSTANCES     16\r
15 \r
16 typedef enum clgecko_buttoneventtype_e {\r
17         CLG_BET_DOWN,\r
18         CLG_BET_UP,\r
19         CLG_BET_DOUBLECLICK,\r
20         // use for up + down (but dont use both)\r
21         CLG_BET_PRESS\r
22 } clgecko_buttoneventtype_t;\r
23 \r
24 typedef struct clgecko_s clgecko_t;\r
25 \r
26 void CL_Gecko_Frame( void );\r
27 void CL_Gecko_Init( void );\r
28 void CL_Gecko_Shutdown( void );\r
29 \r
30 clgecko_t * CL_Gecko_CreateBrowser( const char *name );\r
31 clgecko_t * CL_Gecko_FindBrowser( const char *name );\r
32 void CL_Gecko_DestroyBrowser( clgecko_t *instance );\r
33 \r
34 void CL_Gecko_NavigateToURI( clgecko_t *instance, const char *URI );\r
35 // x and y between 0.0 and 1.0 (0.0 is top-left?)\r
36 void CL_Gecko_Event_CursorMove( clgecko_t *instance, float x, float y );\r
37 \r
38 // returns whether the key/button event was handled or not\r
39 qboolean CL_Gecko_Event_Key( clgecko_t *instance, int key, clgecko_buttoneventtype_t eventtype );\r
40 \r
41 #endif\r
42 \r
43 #endif\r
44 \r