Kernel/VTerm,PTY - Replaced VTerm buffers with PTY hooks
[tpg/acess2.git] / Usermode / Applications / axwin3_src / WM / include / common.h
1 /*
2  * Acess2 Window Manager v3 (axwin3)
3  * - By John Hodge (thePowersGang)
4  *
5  * include/common.h
6  * - Common definitions and functions
7  */
8 #ifndef _COMMON_H_
9 #define _COMMON_H_
10
11 #include <acess/sys.h>
12
13 #define TODO(str)       
14
15 #define ASSERT(expr)    do{if(!(expr)){_SysDebug("%s:%i - ASSERTION FAILED: "#expr, __FILE__, __LINE__);exit(-1);}}while(0)
16
17 #define UNIMPLEMENTED() do{_SysDebug("TODO: Implement %s", __func__); for(;;);}while(0)
18
19 #define AXWIN_VERSION   0x300
20
21 static inline int MIN(int a, int b)     { return (a < b) ? a : b; }
22 static inline int MAX(int a, int b)     { return (a > b) ? a : b; }
23
24 // === GLOBALS ===
25 extern int      giTerminalFD;
26 extern const char       *gsTerminalDevice;
27
28 extern int      giScreenWidth, giScreenHeight;
29
30 // === FUNCTIONS ===
31 // --- Input ---
32 extern int      Input_Init(void);
33 extern void     Input_FillSelect(int *nfds, fd_set *set);
34 extern void     Input_HandleSelect(fd_set *set);
35 // --- IPC ---
36 extern void     IPC_Init(void);
37 extern void     IPC_FillSelect(int *nfds, fd_set *set);
38 extern void     IPC_HandleSelect(fd_set *set);
39
40 #endif
41

UCC git Repository :: git.ucc.asn.au