OSDN Git Service

add stub for xputc2
[jnethack/source.git] / sys / winnt / stubs.c
1 #include "hack.h"
2
3 #ifdef GUISTUB
4 #ifdef TTYSTUB
5 #error You can't compile this with both GUISTUB and TTYSTUB defined.
6 #endif
7
8 int GUILaunched;
9 struct window_procs mswin_procs = { "guistubs" };
10 void
11 mswin_destroy_reg()
12 {
13     return;
14 }
15
16 /* MINGW32 has trouble with both a main() and WinMain()
17  * so we move main for the MINGW tty version into this stub
18  * so that it is out of sight for the gui linkage.
19  */
20 #ifdef __MINGW32__
21 extern char default_window_sys[];
22
23 int
24 main(argc, argv)
25 int argc;
26 char *argv[];
27 {
28     boolean resuming;
29
30     sys_early_init();
31     Strcpy(default_window_sys, "tty");
32     resuming = pcmain(argc, argv);
33     moveloop(resuming);
34     nethack_exit(EXIT_SUCCESS);
35     /*NOTREACHED*/
36     return 0;
37 }
38 #endif
39 #endif /* GUISTUB */
40
41 /* =============================================== */
42
43 #ifdef TTYSTUB
44
45 #include "hack.h"
46
47 int GUILaunched;
48 struct window_procs tty_procs = { "ttystubs" };
49
50 void
51 win_tty_init(dir)
52 int dir;
53 {
54     return;
55 }
56
57 void
58 nttty_open(mode)
59 int mode;
60 {
61     return;
62 }
63
64 void
65 xputc(ch)
66 char ch;
67 {
68     return;
69 }
70
71 #if 1 /*JP*/
72 void
73 xputc2(ch1, ch2)
74 int ch1;
75 int ch2;
76 {
77     return;
78 }
79 #endif
80
81 void
82 xputs(s)
83 const char *s;
84 {
85     return;
86 }
87
88 void
89 raw_clear_screen()
90 {
91     return;
92 }
93
94 void
95 clear_screen()
96 {
97     return;
98 }
99
100 void
101 backsp()
102 {
103     return;
104 }
105
106 int
107 has_color(int color)
108 {
109     return 1;
110 }
111
112 #ifndef NO_MOUSE_ALLOWED
113 void
114 toggle_mouse_support()
115 {
116     return;
117 }
118 #endif
119
120 #ifdef PORT_DEBUG
121 void
122 win32con_debug_keystrokes()
123 {
124     return;
125 }
126 void
127 win32con_handler_info()
128 {
129     return;
130 }
131 #endif
132
133 void
134 map_subkeyvalue(op)
135 register char *op;
136 {
137     return;
138 }
139
140 void
141 load_keyboard_handler()
142 {
143     return;
144 }
145
146 /* this is used as a printf() replacement when the window
147  * system isn't initialized yet
148  */
149 void msmsg
150 VA_DECL(const char *, fmt)
151 {
152     VA_START(fmt);
153     VA_INIT(fmt, const char *);
154     VA_END();
155     return;
156 }
157
158 /*VARARGS1*/
159 void nttty_error
160 VA_DECL(const char *, s)
161 {
162     VA_START(s);
163     VA_INIT(s, const char *);
164     VA_END();
165     return;
166 }
167
168 void
169 synch_cursor()
170 {
171     return;
172 }
173
174 void
175 more()
176 {
177     return;
178 }
179
180 #endif /* TTYSTUBS */