Commit 8bee3b8b1a094e525befd7b6cf0923a1f48a1677
1 parent
84a6f128
Exists in
master
and in
3 other branches
Iniciando inclusao de suporte a acessibilidade
Showing
5 changed files
with
40 additions
and
40 deletions
Show diff stats
appres.h
... | ... | @@ -100,14 +100,16 @@ typedef struct { |
100 | 100 | #endif /*]*/ |
101 | 101 | |
102 | 102 | /* Named resources */ |
103 | -#if defined(X3270_KEYPAD) /*[*/ | |
103 | +/* | |
104 | +#if defined(X3270_KEYPAD) | |
104 | 105 | char *keypad; |
105 | -#endif /*]*/ | |
106 | -#if defined(X3270_DISPLAY) || defined(C3270) /*[*/ | |
106 | +#endif | |
107 | +*/ | |
108 | +#if defined(X3270_DISPLAY) || defined(C3270) | |
107 | 109 | // char *key_map; |
108 | 110 | char *compose_map; |
109 | 111 | char *printer_lu; |
110 | -#endif /*]*/ | |
112 | +#endif | |
111 | 113 | /* |
112 | 114 | #if defined(X3270_DISPLAY) |
113 | 115 | char *efontname; | ... | ... |
... | ... | @@ -375,14 +375,14 @@ ft_aborting(void) |
375 | 375 | static void ft_connected(H3270 *session, int ignored, void *dunno) |
376 | 376 | { |
377 | 377 | if (!CONNECTED && ft_state != FT_NONE) |
378 | - ft_complete(MSG_("ftDisconnected","Host disconnected, transfer cancelled")); | |
378 | + ft_complete(_("Host disconnected, transfer cancelled")); | |
379 | 379 | } |
380 | 380 | |
381 | 381 | /* Process an abort from no longer being in 3270 mode. */ |
382 | 382 | static void ft_in3270(H3270 *session, int ignored, void *dunno) |
383 | 383 | { |
384 | 384 | if (!IN_3270 && ft_state != FT_NONE) |
385 | - ft_complete(MSG_("ftNot3270","Not in 3270 mode, transfer cancelled")); | |
385 | + ft_complete(_("Not in 3270 mode, transfer cancelled")); | |
386 | 386 | } |
387 | 387 | |
388 | 388 | #endif | ... | ... |
ft_cut.c
... | ... | @@ -160,8 +160,7 @@ upload_convert(unsigned char *buf, int len) |
160 | 160 | break; |
161 | 161 | } |
162 | 162 | if (quadrant >= NQ) { |
163 | - cut_abort(MSG_("ftCutConversionError","Data conversion error"), | |
164 | - SC_ABORT_XMIT); | |
163 | + cut_abort(_("Data conversion error"),SC_ABORT_XMIT); | |
165 | 164 | return -1; |
166 | 165 | } |
167 | 166 | continue; |
... | ... | @@ -169,8 +168,7 @@ upload_convert(unsigned char *buf, int len) |
169 | 168 | |
170 | 169 | /* Make sure it's in a valid range. */ |
171 | 170 | if (c < 0x40 || c > 0xf9) { |
172 | - cut_abort(MSG_("ftCutConversionError","Data conversion error"), | |
173 | - SC_ABORT_XMIT); | |
171 | + cut_abort(_("Data conversion error"),SC_ABORT_XMIT); | |
174 | 172 | return -1; |
175 | 173 | } |
176 | 174 | |
... | ... | @@ -291,7 +289,7 @@ ft_cut_data(void) |
291 | 289 | break; |
292 | 290 | default: |
293 | 291 | trace_ds("< FT unknown 0x%02x\n", ea_buf[O_FRAME_TYPE].cc); |
294 | - cut_abort(MSG_("ftCutUnknownFrame"," Unknown frame type from host"), SC_ABORT_XMIT); | |
292 | + cut_abort(_(" Unknown frame type from host"), SC_ABORT_XMIT); | |
295 | 293 | break; |
296 | 294 | } |
297 | 295 | } |
... | ... | @@ -346,14 +344,14 @@ cut_control_code(void) |
346 | 344 | while (bp >= buf && *bp == ' ') |
347 | 345 | *bp-- = '\0'; |
348 | 346 | if (!*buf) |
349 | - strcpy(buf, MSG_("ftHostCancel","Transfer cancelled by host")); | |
347 | + strcpy(buf, _("Transfer cancelled by host")); | |
350 | 348 | } |
351 | 349 | ft_complete(buf); |
352 | 350 | Free(buf); |
353 | 351 | break; |
354 | 352 | default: |
355 | 353 | trace_ds("unknown 0x%04x\n", code); |
356 | - cut_abort(MSG_("ftCutUnknownControl","Unknown FT control code from host"), SC_ABORT_XMIT); | |
354 | + cut_abort(_("Unknown FT control code from host"), SC_ABORT_XMIT); | |
357 | 355 | break; |
358 | 356 | } |
359 | 357 | } |
... | ... | @@ -373,7 +371,7 @@ cut_data_request(void) |
373 | 371 | |
374 | 372 | trace_ds("< FT DATA_REQUEST %u\n", from6(seq)); |
375 | 373 | if (ft_state == FT_ABORT_WAIT) { |
376 | - cut_abort(MSG_("ftUserCancel","Transfer cancelled by user"), SC_ABORT_FILE); | |
374 | + cut_abort(_("Transfer cancelled by user"), SC_ABORT_FILE); | |
377 | 375 | return; |
378 | 376 | } |
379 | 377 | |
... | ... | @@ -394,8 +392,7 @@ cut_data_request(void) |
394 | 392 | ctlr_add(O_UP_DATA + j, 0, 0); |
395 | 393 | |
396 | 394 | /* Abort the transfer. */ |
397 | - msg = xs_buffer("read(%s): %s", ft_local_filename, | |
398 | - strerror(errno)); | |
395 | + msg = xs_buffer("read(%s): %s", ft_local_filename,strerror(errno)); | |
399 | 396 | cut_abort(msg, SC_ABORT_FILE); |
400 | 397 | Free(msg); |
401 | 398 | return; |
... | ... | @@ -437,7 +434,7 @@ static void |
437 | 434 | cut_retransmit(void) |
438 | 435 | { |
439 | 436 | trace_ds("< FT RETRANSMIT\n"); |
440 | - cut_abort(MSG_("ftCutRetransmit","Transmission error"), SC_ABORT_XMIT); | |
437 | + cut_abort(_("Transmission error"), SC_ABORT_XMIT); | |
441 | 438 | } |
442 | 439 | |
443 | 440 | /* |
... | ... | @@ -468,7 +465,7 @@ cut_data(void) |
468 | 465 | |
469 | 466 | trace_ds("< FT DATA\n"); |
470 | 467 | if (ft_state == FT_ABORT_WAIT) { |
471 | - cut_abort(MSG_("ftUserCancel","Transfer cancelled by user"), SC_ABORT_FILE); | |
468 | + cut_abort(_("Transfer cancelled by user"), SC_ABORT_FILE); | |
472 | 469 | return; |
473 | 470 | } |
474 | 471 | |
... | ... | @@ -476,7 +473,7 @@ cut_data(void) |
476 | 473 | raw_length = from6(h3270.ea_buf[O_DT_LEN].cc) << 6 | |
477 | 474 | from6(h3270.ea_buf[O_DT_LEN + 1].cc); |
478 | 475 | if ((int)raw_length > O_RESPONSE - O_DT_DATA) { |
479 | - cut_abort(MSG_("ftCutOversize","Illegal frame length"), SC_ABORT_XMIT); | |
476 | + cut_abort(_("Illegal frame length"), SC_ABORT_XMIT); | |
480 | 477 | return; |
481 | 478 | } |
482 | 479 | for (i = 0; i < (int)raw_length; i++) | ... | ... |
ft_dft.c
... | ... | @@ -162,7 +162,7 @@ dft_open_request(unsigned short len, unsigned char *cp) |
162 | 162 | GET16(recsz, recszp); |
163 | 163 | name = (char *)cp + 31; |
164 | 164 | } else { |
165 | - dft_abort(MSG_("ftDftUknownOpen","ftDftUknownOpen"), TR_OPEN_REQ); | |
165 | + dft_abort( _("ftDftUknownOpen"), TR_OPEN_REQ); | |
166 | 166 | return; |
167 | 167 | } |
168 | 168 | |
... | ... | @@ -215,7 +215,7 @@ dft_data_insert(struct data_buffer *data_bufr) |
215 | 215 | unsigned char *cp; |
216 | 216 | |
217 | 217 | if (!message_flag && ft_state == FT_ABORT_WAIT) { |
218 | - dft_abort( MSG_("ftUserCancel","Transfer cancelled by user"), TR_DATA_INSERT); | |
218 | + dft_abort( _("Transfer cancelled by user"), TR_DATA_INSERT); | |
219 | 219 | return; |
220 | 220 | } |
221 | 221 | |
... | ... | @@ -352,7 +352,7 @@ dft_get_request(void) |
352 | 352 | trace_ds(" Get\n"); |
353 | 353 | |
354 | 354 | if (!message_flag && ft_state == FT_ABORT_WAIT) { |
355 | - dft_abort(MSG_("ftUserCancel","Transfer cancelled by user"), TR_GET_REQ); | |
355 | + dft_abort(_("Transfer cancelled by user"), TR_GET_REQ); | |
356 | 356 | return; |
357 | 357 | } |
358 | 358 | ... | ... |
globals.h
... | ... | @@ -59,11 +59,9 @@ |
59 | 59 | #include <libintl.h> |
60 | 60 | #define _( x ) gettext(x) |
61 | 61 | #define N_( x ) x |
62 | - #define MSG_( c, s ) gettext(s) | |
63 | 62 | #else |
64 | 63 | #define _( x ) x |
65 | 64 | #define N_( x ) x |
66 | - #define MSG_( c, s ) s | |
67 | 65 | #endif // HAVE_LIBINTL |
68 | 66 | |
69 | 67 | |
... | ... | @@ -120,23 +118,24 @@ |
120 | 118 | #undef X3270_MENUS |
121 | 119 | #endif /*]*/ |
122 | 120 | |
123 | -/* Local process (-e) header files. */ | |
124 | -#if defined(X3270_LOCAL_PROCESS) && defined(HAVE_LIBUTIL) /*[*/ | |
121 | +/* Local process (-e) header files. */ /* | |
122 | +#if defined(X3270_LOCAL_PROCESS) && defined(HAVE_LIBUTIL) | |
125 | 123 | #define LOCAL_PROCESS 1 |
126 | 124 | #include <termios.h> |
127 | 125 | |
128 | - #if defined(HAVE_PTY_H) /*[*/ | |
126 | + #if defined(HAVE_PTY_H) | |
129 | 127 | #include <pty.h> |
130 | - #endif /*]*/ | |
128 | + #endif | |
131 | 129 | |
132 | - #if defined(HAVE_LIBUTIL_H) /*[*/ | |
130 | + #if defined(HAVE_LIBUTIL_H) | |
133 | 131 | #include <libutil.h> |
134 | - #endif /*]*/ | |
132 | + #endif | |
135 | 133 | |
136 | - #if defined(HAVE_UTIL_H) /*[*/ | |
134 | + #if defined(HAVE_UTIL_H) | |
137 | 135 | #include <util.h> |
138 | - #endif /*]*/ | |
139 | -#endif /*]*/ | |
136 | + #endif | |
137 | +#endif | |
138 | +*/ | |
140 | 139 | |
141 | 140 | /* Functions we may need to supply. */ |
142 | 141 | #if defined(NEED_STRTOK_R) /*[*/ |
... | ... | @@ -182,26 +181,28 @@ LIB3270_INTERNAL int children; |
182 | 181 | LIB3270_INTERNAL int dft_buffersize; |
183 | 182 | #endif /*]*/ |
184 | 183 | |
185 | -LIB3270_INTERNAL char *efontname; | |
184 | +// LIB3270_INTERNAL char *efontname; | |
186 | 185 | LIB3270_INTERNAL Boolean ever_3270; |
187 | 186 | LIB3270_INTERNAL Boolean exiting; |
188 | 187 | |
189 | -#if defined(X3270_DISPLAY) /*[*/ | |
188 | +/* | |
189 | +#if defined(X3270_DISPLAY) | |
190 | 190 | LIB3270_INTERNAL Boolean *extended_3270font; |
191 | 191 | LIB3270_INTERNAL Font *fid; |
192 | 192 | LIB3270_INTERNAL Boolean *font_8bit; |
193 | -#endif /*]*/ | |
193 | +#endif | |
194 | +*/ | |
194 | 195 | |
195 | 196 | // LIB3270_INTERNAL Boolean flipped; |
196 | -LIB3270_INTERNAL char *full_current_host; | |
197 | -LIB3270_INTERNAL char *full_efontname; | |
197 | +// LIB3270_INTERNAL char *full_current_host; | |
198 | +// LIB3270_INTERNAL char *full_efontname; | |
198 | 199 | |
199 | 200 | #if defined(X3270_DBCS) /*[*/ |
200 | 201 | LIB3270_INTERNAL char *full_efontname_dbcs; |
201 | 202 | #endif /*]*/ |
202 | 203 | |
203 | -LIB3270_INTERNAL char *funky_font; | |
204 | -LIB3270_INTERNAL char *hostname; | |
204 | +//LIB3270_INTERNAL char *funky_font; | |
205 | +//LIB3270_INTERNAL char *hostname; | |
205 | 206 | |
206 | 207 | #if defined(X3270_DBCS) /*[*/ |
207 | 208 | LIB3270_INTERNAL char *local_encoding; | ... | ... |