]> icculus.org git repositories - divverent/nexuiz.git/blob - data/menuqc/system/isframe.qh
rename menu directories
[divverent/nexuiz.git] / data / menuqc / system / isframe.qh
1 // DP/Nex Menu
2 // system/isframe.qh
3
4 // define these menus in the menu def files or dont
5 // if not defined there will be added default items
6 const string MENU_NORMAL_NAME = "Normal";
7 const string MENU_INGAME_NAME = "Ingame";
8
9 const string MENU_NORMAL_DEFAULT =
10 "// default normal menu\n"
11 "{\n"
12 "       \"type\"        \"Item_Window\"\n"
13 "       \"name\"        \"Normal\"\n"
14 "}";
15
16 const string MENU_INGAME_DEFAULT =
17 "// default ingame menu\n"
18 "{\n"
19 "       \"type\"        \"Item_Window\"\n"
20 "       \"name\"                \"Ingame\"\n"
21 "}";
22
23 // insert the files here
24 var string MENU_MAINFILE = "menu/menu";
25 var string MENU_PLUGINDIR = "menu/plugin";
26
27 const bool MENU_ALLOWINGAME = false;
28
29 ///////////////
30 // prototypes
31 ///
32
33 // used for global managing
34 void() Menu_Init;
35 // loads all files the file lists consists of
36 void() Menu_Load;
37 // used to reset the menu states everytime the menu is activated
38 void() Menu_PerformReinit;
39 // called when the hide event is processed
40 void() Menu_Hide;
41 // unload the menu
42 void() Menu_Shutdown;
43
44 // For runtime addition of items, there is one function:
45 // it supposes that the Item has already been embedded into its parent
46 void( entity pItem ) Menu_LinkItem; // does also link all children and call their spawn function if necessary
47 void( entity pWindow ) Menu_LinkWindow;
48
49  // to make life easier
50 entity( string pType, string pName, string pParent ) Menu_CreateItem;
51 entity( entity pTemplate, string pName, string pParent, bool pTree ) Menu_DeriveItem;
52
53 void( entity pItem, string pData ) Menu_AddEntityData;
54
55 // these functions are pretty private, so dont call them !
56 void( entity pParent ) Menu_LinkChildren;
57 void() Menu_LinkWindows;