|
Revision 487, 1.8 kB
(checked in by mwhitworth, 4 months ago)
|
|
Add to and tidy up various header files.
|
| Line | |
|---|
| 1 | |
|---|
| 2 | |
|---|
| 3 | |
|---|
| 4 | |
|---|
| 5 | |
|---|
| 6 | |
|---|
| 7 | |
|---|
| 8 | |
|---|
| 9 | |
|---|
| 10 | |
|---|
| 11 | |
|---|
| 12 | |
|---|
| 13 | |
|---|
| 14 | |
|---|
| 15 | |
|---|
| 16 | |
|---|
| 17 | |
|---|
| 18 | |
|---|
| 19 | #ifndef CONSOLE_H |
|---|
| 20 | #define CONSOLE_H |
|---|
| 21 | |
|---|
| 22 | #include <typedefs.h> |
|---|
| 23 | #include <wait.h> |
|---|
| 24 | |
|---|
| 25 | int ConsoleEarlyInit(); |
|---|
| 26 | void ConsoleClearCurrent(); |
|---|
| 27 | void ConsoleSwitchToText(); |
|---|
| 28 | #define puts(s) printf(s) |
|---|
| 29 | int printf(char* str,...); |
|---|
| 30 | void putc(int c); |
|---|
| 31 | |
|---|
| 32 | int ChangeConsole(int index); |
|---|
| 33 | void ConsoleAddKey(BYTE n); |
|---|
| 34 | void ConsoleAddKeyCode(BYTE n); |
|---|
| 35 | |
|---|
| 36 | #define MAX_CONSOLES 7 |
|---|
| 37 | |
|---|
| 38 | extern int currConsole; |
|---|
| 39 | |
|---|
| 40 | struct Console |
|---|
| 41 | { |
|---|
| 42 | WORD currX,currY,currColor; |
|---|
| 43 | WaitQueue waitQueue; |
|---|
| 44 | BYTE keyboardBuf[25]; |
|---|
| 45 | BYTE head,tail; |
|---|
| 46 | unsigned int params[16]; |
|---|
| 47 | int inCtrl,ctrlParams,cmdLetter,paramIndex; |
|---|
| 48 | int flags; |
|---|
| 49 | }; |
|---|
| 50 | |
|---|
| 51 | extern struct Console consoles[MAX_CONSOLES]; |
|---|
| 52 | |
|---|
| 53 | |
|---|
| 54 | #define CONSOLE_SET_OPTIONS 0x00000001 |
|---|
| 55 | #define CONSOLE_GET_OPTIONS 0x00000002 |
|---|
| 56 | #define CONSOLE_GET_INFO 0x00000003 |
|---|
| 57 | |
|---|
| 58 | |
|---|
| 59 | #define CONSOLE_NO_ECHO 0x00000001 |
|---|
| 60 | #define CONSOLE_GRAPHICS 0x00000002 |
|---|
| 61 | #define CONSOLE_SENDKEYC 0x00000004 |
|---|
| 62 | |
|---|
| 63 | |
|---|
| 64 | |
|---|
| 65 | struct ConsoleInfo |
|---|
| 66 | { |
|---|
| 67 | int rows,cols; |
|---|
| 68 | }; |
|---|
| 69 | |
|---|
| 70 | #endif |
|---|