Commit bb0b189d3705844d0ee01f7c50f72be1838dd600
1 parent
f34a300b
Exists in
master
and in
5 other branches
Iniciando inclusao de suporte a acessibilidade
Showing
12 changed files
with
198 additions
and
46 deletions
Show diff stats
Makefile.in
@@ -58,6 +58,7 @@ MKDIR=@MKDIR_P@ | @@ -58,6 +58,7 @@ MKDIR=@MKDIR_P@ | ||
58 | INSTALL=@INSTALL@ | 58 | INSTALL=@INSTALL@ |
59 | INSTALL_PROGRAM=@INSTALL_PROGRAM@ | 59 | INSTALL_PROGRAM=@INSTALL_PROGRAM@ |
60 | INSTALL_DATA=@INSTALL_DATA@ | 60 | INSTALL_DATA=@INSTALL_DATA@ |
61 | +RPMBUILD=@RPMBUILD@ | ||
61 | 62 | ||
62 | #---[ Release targets ]-------------------------------------------------------- | 63 | #---[ Release targets ]-------------------------------------------------------- |
63 | 64 | ||
@@ -94,7 +95,15 @@ endif | @@ -94,7 +95,15 @@ endif | ||
94 | tgz: $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz | 95 | tgz: $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz |
95 | 96 | ||
96 | rpm: $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz | 97 | rpm: $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz |
98 | +ifneq ($(RPMBUILD),no) | ||
97 | @rpmbuild -ta $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz | 99 | @rpmbuild -ta $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz |
100 | +endif | ||
101 | + | ||
102 | +srpm: $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz | ||
103 | +ifneq ($(RPMBUILD),no) | ||
104 | + @rpmbuild -ts $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz | ||
105 | +endif | ||
106 | + | ||
98 | 107 | ||
99 | $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz: clean | 108 | $(PACKAGE_TARNAME)-$(PACKAGE_VERSION).tar.gz: clean |
100 | @rm -fr $(TMPDIR)/$(PACKAGE_TARNAME)-$(PACKAGE_VERSION) | 109 | @rm -fr $(TMPDIR)/$(PACKAGE_TARNAME)-$(PACKAGE_VERSION) |
configure.ac
@@ -117,6 +117,7 @@ AC_PATH_TOOL([XGETTEXT], [xgettext], [no]) | @@ -117,6 +117,7 @@ AC_PATH_TOOL([XGETTEXT], [xgettext], [no]) | ||
117 | AC_PATH_TOOL([MSGCAT], [msgcat], [no]) | 117 | AC_PATH_TOOL([MSGCAT], [msgcat], [no]) |
118 | AC_PATH_TOOL([MSGINIT], [msginit], [no]) | 118 | AC_PATH_TOOL([MSGINIT], [msginit], [no]) |
119 | AC_PATH_TOOL([MSGFMT], [msgfmt], [no]) | 119 | AC_PATH_TOOL([MSGFMT], [msgfmt], [no]) |
120 | +AC_PATH_TOOL([RPMBUILD], [rpmbuild], [no]) | ||
120 | 121 | ||
121 | AC_CHECK_HEADER(libintl.h, AC_DEFINE(HAVE_LIBINTL)) | 122 | AC_CHECK_HEADER(libintl.h, AC_DEFINE(HAVE_LIBINTL)) |
122 | AC_CHECK_LIB(intl, gettext,[INTL_LIBS="-lintl"]) | 123 | AC_CHECK_LIB(intl, gettext,[INTL_LIBS="-lintl"]) |
src/gtk/print.c
@@ -295,21 +295,23 @@ static gchar * enum_to_string(GType type, guint enum_value) | @@ -295,21 +295,23 @@ static gchar * enum_to_string(GType type, guint enum_value) | ||
295 | 295 | ||
296 | static GObject * create_custom_widget(GtkPrintOperation *prt, PRINT_INFO *info) | 296 | static GObject * create_custom_widget(GtkPrintOperation *prt, PRINT_INFO *info) |
297 | { | 297 | { |
298 | - static const gchar * label[] = { N_( "Font:" ), N_( "Color scheme:" ) }; | 298 | + static const gchar * text[] = { N_( "_Font:" ), N_( "C_olor scheme:" ) }; |
299 | GtkWidget * container = gtk_table_new(3,2,FALSE); | 299 | GtkWidget * container = gtk_table_new(3,2,FALSE); |
300 | + GtkWidget * label[G_N_ELEMENTS(text)]; | ||
300 | GtkWidget * widget; | 301 | GtkWidget * widget; |
301 | int f; | 302 | int f; |
302 | gchar * ptr; | 303 | gchar * ptr; |
303 | 304 | ||
304 | for(f=0;f<G_N_ELEMENTS(label);f++) | 305 | for(f=0;f<G_N_ELEMENTS(label);f++) |
305 | { | 306 | { |
306 | - widget = gtk_label_new(gettext(label[f])); | ||
307 | - gtk_misc_set_alignment(GTK_MISC(widget),0,0.5); | ||
308 | - gtk_table_attach(GTK_TABLE(container),widget,0,1,f,f+1,GTK_FILL,GTK_FILL,0,0); | 307 | + label[f] = gtk_label_new_with_mnemonic(gettext(text[f])); |
308 | + gtk_misc_set_alignment(GTK_MISC(label[f]),0,0.5); | ||
309 | + gtk_table_attach(GTK_TABLE(container),label[f],0,1,f,f+1,GTK_FILL,GTK_FILL,0,0); | ||
309 | } | 310 | } |
310 | 311 | ||
311 | // Font selection button | 312 | // Font selection button |
312 | widget = gtk_font_button_new(); | 313 | widget = gtk_font_button_new(); |
314 | + gtk_label_set_mnemonic_widget(GTK_LABEL(label[0]),widget); | ||
313 | 315 | ||
314 | #if GTK_CHECK_VERSION(3,2,0) | 316 | #if GTK_CHECK_VERSION(3,2,0) |
315 | gtk_font_chooser_set_filter_func((GtkFontChooser *) widget,filter_monospaced,NULL,NULL); | 317 | gtk_font_chooser_set_filter_func((GtkFontChooser *) widget,filter_monospaced,NULL,NULL); |
@@ -330,6 +332,7 @@ static gchar * enum_to_string(GType type, guint enum_value) | @@ -330,6 +332,7 @@ static gchar * enum_to_string(GType type, guint enum_value) | ||
330 | g_free(ptr); | 332 | g_free(ptr); |
331 | 333 | ||
332 | widget = color_scheme_new(info->color); | 334 | widget = color_scheme_new(info->color); |
335 | + gtk_label_set_mnemonic_widget(GTK_LABEL(label[1]),widget); | ||
333 | 336 | ||
334 | g_object_set_data(G_OBJECT(container),"combo",widget); | 337 | g_object_set_data(G_OBJECT(container),"combo",widget); |
335 | gtk_table_attach(GTK_TABLE(container),widget,1,2,1,2,GTK_EXPAND|GTK_FILL,GTK_FILL,5,0); | 338 | gtk_table_attach(GTK_TABLE(container),widget,1,2,1,2,GTK_EXPAND|GTK_FILL,GTK_FILL,5,0); |
@@ -0,0 +1,81 @@ | @@ -0,0 +1,81 @@ | ||
1 | +/* | ||
2 | + * "Software pw3270, desenvolvido com base nos códigos fontes do WC3270 e X3270 | ||
3 | + * (Paul Mattes Paul.Mattes@usa.net), de emulação de terminal 3270 para acesso a | ||
4 | + * aplicativos mainframe. Registro no INPI sob o nome G3270. | ||
5 | + * | ||
6 | + * Copyright (C) <2008> <Banco do Brasil S.A.> | ||
7 | + * | ||
8 | + * Este programa é software livre. Você pode redistribuí-lo e/ou modificá-lo sob | ||
9 | + * os termos da GPL v.2 - Licença Pública Geral GNU, conforme publicado pela | ||
10 | + * Free Software Foundation. | ||
11 | + * | ||
12 | + * Este programa é distribuído na expectativa de ser útil, mas SEM QUALQUER | ||
13 | + * GARANTIA; sem mesmo a garantia implícita de COMERCIALIZAÇÃO ou de ADEQUAÇÃO | ||
14 | + * A QUALQUER PROPÓSITO EM PARTICULAR. Consulte a Licença Pública Geral GNU para | ||
15 | + * obter mais detalhes. | ||
16 | + * | ||
17 | + * Você deve ter recebido uma cópia da Licença Pública Geral GNU junto com este | ||
18 | + * programa; se não, escreva para a Free Software Foundation, Inc., 59 Temple | ||
19 | + * Place, Suite 330, Boston, MA, 02111-1307, USA | ||
20 | + * | ||
21 | + * Este programa está nomeado como accessible.c e possui - linhas de código. | ||
22 | + * | ||
23 | + * Contatos: | ||
24 | + * | ||
25 | + * perry.werneck@gmail.com (Alexandre Perry de Souza Werneck) | ||
26 | + * erico.mendonca@gmail.com (Erico Mascarenhas Mendonça) | ||
27 | + * | ||
28 | + */ | ||
29 | + | ||
30 | + #include <gtk/gtk.h> | ||
31 | + #include "v3270.h" | ||
32 | + #include "accessible.h" | ||
33 | + | ||
34 | +// References: | ||
35 | +// | ||
36 | +// http://git.gnome.org/browse/gtk+/tree/gtk/a11y/gtkwidgetaccessible.c | ||
37 | +// http://git.gnome.org/browse/gtk+/tree/gtk/a11y/gtkentryaccessible.c | ||
38 | +// | ||
39 | + | ||
40 | +/*--[ Prototipes ]-----------------------------------------------------------------------------------*/ | ||
41 | + | ||
42 | +static void atk_editable_text_interface_init (AtkEditableTextIface *iface); | ||
43 | +static void atk_text_interface_init (AtkTextIface *iface); | ||
44 | +static void atk_action_interface_init (AtkActionIface *iface); | ||
45 | +static void v3270_accessible_class_init (v3270AccessibleClass *klass); | ||
46 | +static void v3270_accessible_init (v3270Accessible *widget); | ||
47 | + | ||
48 | +/*--[ Widget definition ]----------------------------------------------------------------------------*/ | ||
49 | + | ||
50 | +G_DEFINE_TYPE_WITH_CODE (v3270Accessible, v3270_accessible, GTK_TYPE_V3270_ACCESSIBLE, | ||
51 | + G_IMPLEMENT_INTERFACE (ATK_TYPE_EDITABLE_TEXT, atk_editable_text_interface_init) | ||
52 | + G_IMPLEMENT_INTERFACE (ATK_TYPE_TEXT, atk_text_interface_init) | ||
53 | + G_IMPLEMENT_INTERFACE (ATK_TYPE_ACTION, atk_action_interface_init)) | ||
54 | + | ||
55 | +/*--[ Implement ]------------------------------------------------------------------------------------*/ | ||
56 | + | ||
57 | +static void v3270_accessible_class_init(v3270AccessibleClass *klass) | ||
58 | +{ | ||
59 | + | ||
60 | +} | ||
61 | + | ||
62 | +static void v3270_accessible_init(v3270Accessible *widget) | ||
63 | +{ | ||
64 | + | ||
65 | +} | ||
66 | + | ||
67 | +static void atk_editable_text_interface_init(AtkEditableTextIface *iface) | ||
68 | +{ | ||
69 | + | ||
70 | +} | ||
71 | + | ||
72 | +static void atk_text_interface_init(AtkTextIface *iface) | ||
73 | +{ | ||
74 | + | ||
75 | +} | ||
76 | + | ||
77 | +static void atk_action_interface_init(AtkActionIface *iface) | ||
78 | +{ | ||
79 | + | ||
80 | +} | ||
81 | + |
@@ -0,0 +1,58 @@ | @@ -0,0 +1,58 @@ | ||
1 | +/* | ||
2 | + * "Software pw3270, desenvolvido com base nos códigos fontes do WC3270 e X3270 | ||
3 | + * (Paul Mattes Paul.Mattes@usa.net), de emulação de terminal 3270 para acesso a | ||
4 | + * aplicativos mainframe. Registro no INPI sob o nome G3270. | ||
5 | + * | ||
6 | + * Copyright (C) <2008> <Banco do Brasil S.A.> | ||
7 | + * | ||
8 | + * Este programa é software livre. Você pode redistribuí-lo e/ou modificá-lo sob | ||
9 | + * os termos da GPL v.2 - Licença Pública Geral GNU, conforme publicado pela | ||
10 | + * Free Software Foundation. | ||
11 | + * | ||
12 | + * Este programa é distribuído na expectativa de ser útil, mas SEM QUALQUER | ||
13 | + * GARANTIA; sem mesmo a garantia implícita de COMERCIALIZAÇÃO ou de ADEQUAÇÃO | ||
14 | + * A QUALQUER PROPÓSITO EM PARTICULAR. Consulte a Licença Pública Geral GNU para | ||
15 | + * obter mais detalhes. | ||
16 | + * | ||
17 | + * Você deve ter recebido uma cópia da Licença Pública Geral GNU junto com este | ||
18 | + * programa; se não, escreva para a Free Software Foundation, Inc., 59 Temple | ||
19 | + * Place, Suite 330, Boston, MA, 02111-1307, USA | ||
20 | + * | ||
21 | + * Este programa está nomeado como accessible.h e possui - linhas de código. | ||
22 | + * | ||
23 | + * Contatos: | ||
24 | + * | ||
25 | + * perry.werneck@gmail.com (Alexandre Perry de Souza Werneck) | ||
26 | + * erico.mendonca@gmail.com (Erico Mascarenhas Mendonça) | ||
27 | + * | ||
28 | + */ | ||
29 | + | ||
30 | +#include <gtk/gtk.h> | ||
31 | + | ||
32 | +G_BEGIN_DECLS | ||
33 | + | ||
34 | +#define GTK_TYPE_V3270_ACCESSIBLE (v3270_accessible_get_type ()) | ||
35 | +#define GTK_V3270_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_V3270_ACCESSIBLE, v3270Accessible)) | ||
36 | +#define GTK_V3270_ACCESSIBLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GTK_TYPE_V3270_ACCESSIBLE, v3270AccessibleClass)) | ||
37 | +#define GTK_IS_V3270_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_TYPE_V3270_ACCESSIBLE)) | ||
38 | +#define GTK_IS_V3270_ACCESSIBLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GTK_TYPE_V3270_ACCESSIBLE)) | ||
39 | +#define GTK_V3270_ACCESSIBLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GTK_TYPE_V3270_ACCESSIBLE, v3270AccessibleClass)) | ||
40 | + | ||
41 | +typedef struct _v3270Accessible v3270Accessible; | ||
42 | +typedef struct _v3270AccessibleClass v3270AccessibleClass; | ||
43 | + | ||
44 | +struct _v3270Accessible | ||
45 | +{ | ||
46 | + GtkAccessible parent; | ||
47 | + | ||
48 | + AtkLayer layer; | ||
49 | +}; | ||
50 | + | ||
51 | +struct _v3270AccessibleClass | ||
52 | +{ | ||
53 | + GtkAccessibleClass parent_class; | ||
54 | + | ||
55 | + | ||
56 | +}; | ||
57 | + | ||
58 | +G_END_DECLS |
src/gtk/v3270/sources.mak
src/gtk/v3270/widget.c
@@ -35,8 +35,8 @@ | @@ -35,8 +35,8 @@ | ||
35 | #include <lib3270/log.h> | 35 | #include <lib3270/log.h> |
36 | #include "v3270.h" | 36 | #include "v3270.h" |
37 | #include "private.h" | 37 | #include "private.h" |
38 | + #include "accessible.h" | ||
38 | #include "marshal.h" | 39 | #include "marshal.h" |
39 | - #include "../common/common.h" | ||
40 | 40 | ||
41 | #define WIDTH_IN_PIXELS(terminal,x) (x * cols) | 41 | #define WIDTH_IN_PIXELS(terminal,x) (x * cols) |
42 | #define HEIGHT_IN_PIXELS(terminal,x) (x * (rows+1)) | 42 | #define HEIGHT_IN_PIXELS(terminal,x) (x * (rows+1)) |
src/lib3270/appres.h
@@ -100,14 +100,16 @@ typedef struct { | @@ -100,14 +100,16 @@ typedef struct { | ||
100 | #endif /*]*/ | 100 | #endif /*]*/ |
101 | 101 | ||
102 | /* Named resources */ | 102 | /* Named resources */ |
103 | -#if defined(X3270_KEYPAD) /*[*/ | 103 | +/* |
104 | +#if defined(X3270_KEYPAD) | ||
104 | char *keypad; | 105 | char *keypad; |
105 | -#endif /*]*/ | ||
106 | -#if defined(X3270_DISPLAY) || defined(C3270) /*[*/ | 106 | +#endif |
107 | +*/ | ||
108 | +#if defined(X3270_DISPLAY) || defined(C3270) | ||
107 | // char *key_map; | 109 | // char *key_map; |
108 | char *compose_map; | 110 | char *compose_map; |
109 | char *printer_lu; | 111 | char *printer_lu; |
110 | -#endif /*]*/ | 112 | +#endif |
111 | /* | 113 | /* |
112 | #if defined(X3270_DISPLAY) | 114 | #if defined(X3270_DISPLAY) |
113 | char *efontname; | 115 | char *efontname; |
src/lib3270/ft.c
@@ -375,14 +375,14 @@ ft_aborting(void) | @@ -375,14 +375,14 @@ ft_aborting(void) | ||
375 | static void ft_connected(H3270 *session, int ignored, void *dunno) | 375 | static void ft_connected(H3270 *session, int ignored, void *dunno) |
376 | { | 376 | { |
377 | if (!CONNECTED && ft_state != FT_NONE) | 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 | /* Process an abort from no longer being in 3270 mode. */ | 381 | /* Process an abort from no longer being in 3270 mode. */ |
382 | static void ft_in3270(H3270 *session, int ignored, void *dunno) | 382 | static void ft_in3270(H3270 *session, int ignored, void *dunno) |
383 | { | 383 | { |
384 | if (!IN_3270 && ft_state != FT_NONE) | 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 | #endif | 388 | #endif |
src/lib3270/ft_cut.c
@@ -160,8 +160,7 @@ upload_convert(unsigned char *buf, int len) | @@ -160,8 +160,7 @@ upload_convert(unsigned char *buf, int len) | ||
160 | break; | 160 | break; |
161 | } | 161 | } |
162 | if (quadrant >= NQ) { | 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 | return -1; | 164 | return -1; |
166 | } | 165 | } |
167 | continue; | 166 | continue; |
@@ -169,8 +168,7 @@ upload_convert(unsigned char *buf, int len) | @@ -169,8 +168,7 @@ upload_convert(unsigned char *buf, int len) | ||
169 | 168 | ||
170 | /* Make sure it's in a valid range. */ | 169 | /* Make sure it's in a valid range. */ |
171 | if (c < 0x40 || c > 0xf9) { | 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 | return -1; | 172 | return -1; |
175 | } | 173 | } |
176 | 174 | ||
@@ -291,7 +289,7 @@ ft_cut_data(void) | @@ -291,7 +289,7 @@ ft_cut_data(void) | ||
291 | break; | 289 | break; |
292 | default: | 290 | default: |
293 | trace_ds("< FT unknown 0x%02x\n", ea_buf[O_FRAME_TYPE].cc); | 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 | break; | 293 | break; |
296 | } | 294 | } |
297 | } | 295 | } |
@@ -346,14 +344,14 @@ cut_control_code(void) | @@ -346,14 +344,14 @@ cut_control_code(void) | ||
346 | while (bp >= buf && *bp == ' ') | 344 | while (bp >= buf && *bp == ' ') |
347 | *bp-- = '\0'; | 345 | *bp-- = '\0'; |
348 | if (!*buf) | 346 | if (!*buf) |
349 | - strcpy(buf, MSG_("ftHostCancel","Transfer cancelled by host")); | 347 | + strcpy(buf, _("Transfer cancelled by host")); |
350 | } | 348 | } |
351 | ft_complete(buf); | 349 | ft_complete(buf); |
352 | Free(buf); | 350 | Free(buf); |
353 | break; | 351 | break; |
354 | default: | 352 | default: |
355 | trace_ds("unknown 0x%04x\n", code); | 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 | break; | 355 | break; |
358 | } | 356 | } |
359 | } | 357 | } |
@@ -373,7 +371,7 @@ cut_data_request(void) | @@ -373,7 +371,7 @@ cut_data_request(void) | ||
373 | 371 | ||
374 | trace_ds("< FT DATA_REQUEST %u\n", from6(seq)); | 372 | trace_ds("< FT DATA_REQUEST %u\n", from6(seq)); |
375 | if (ft_state == FT_ABORT_WAIT) { | 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 | return; | 375 | return; |
378 | } | 376 | } |
379 | 377 | ||
@@ -394,8 +392,7 @@ cut_data_request(void) | @@ -394,8 +392,7 @@ cut_data_request(void) | ||
394 | ctlr_add(O_UP_DATA + j, 0, 0); | 392 | ctlr_add(O_UP_DATA + j, 0, 0); |
395 | 393 | ||
396 | /* Abort the transfer. */ | 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 | cut_abort(msg, SC_ABORT_FILE); | 396 | cut_abort(msg, SC_ABORT_FILE); |
400 | Free(msg); | 397 | Free(msg); |
401 | return; | 398 | return; |
@@ -437,7 +434,7 @@ static void | @@ -437,7 +434,7 @@ static void | ||
437 | cut_retransmit(void) | 434 | cut_retransmit(void) |
438 | { | 435 | { |
439 | trace_ds("< FT RETRANSMIT\n"); | 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,7 +465,7 @@ cut_data(void) | ||
468 | 465 | ||
469 | trace_ds("< FT DATA\n"); | 466 | trace_ds("< FT DATA\n"); |
470 | if (ft_state == FT_ABORT_WAIT) { | 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 | return; | 469 | return; |
473 | } | 470 | } |
474 | 471 | ||
@@ -476,7 +473,7 @@ cut_data(void) | @@ -476,7 +473,7 @@ cut_data(void) | ||
476 | raw_length = from6(h3270.ea_buf[O_DT_LEN].cc) << 6 | | 473 | raw_length = from6(h3270.ea_buf[O_DT_LEN].cc) << 6 | |
477 | from6(h3270.ea_buf[O_DT_LEN + 1].cc); | 474 | from6(h3270.ea_buf[O_DT_LEN + 1].cc); |
478 | if ((int)raw_length > O_RESPONSE - O_DT_DATA) { | 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 | return; | 477 | return; |
481 | } | 478 | } |
482 | for (i = 0; i < (int)raw_length; i++) | 479 | for (i = 0; i < (int)raw_length; i++) |
src/lib3270/ft_dft.c
@@ -162,7 +162,7 @@ dft_open_request(unsigned short len, unsigned char *cp) | @@ -162,7 +162,7 @@ dft_open_request(unsigned short len, unsigned char *cp) | ||
162 | GET16(recsz, recszp); | 162 | GET16(recsz, recszp); |
163 | name = (char *)cp + 31; | 163 | name = (char *)cp + 31; |
164 | } else { | 164 | } else { |
165 | - dft_abort(MSG_("ftDftUknownOpen","ftDftUknownOpen"), TR_OPEN_REQ); | 165 | + dft_abort( _("ftDftUknownOpen"), TR_OPEN_REQ); |
166 | return; | 166 | return; |
167 | } | 167 | } |
168 | 168 | ||
@@ -215,7 +215,7 @@ dft_data_insert(struct data_buffer *data_bufr) | @@ -215,7 +215,7 @@ dft_data_insert(struct data_buffer *data_bufr) | ||
215 | unsigned char *cp; | 215 | unsigned char *cp; |
216 | 216 | ||
217 | if (!message_flag && ft_state == FT_ABORT_WAIT) { | 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 | return; | 219 | return; |
220 | } | 220 | } |
221 | 221 | ||
@@ -352,7 +352,7 @@ dft_get_request(void) | @@ -352,7 +352,7 @@ dft_get_request(void) | ||
352 | trace_ds(" Get\n"); | 352 | trace_ds(" Get\n"); |
353 | 353 | ||
354 | if (!message_flag && ft_state == FT_ABORT_WAIT) { | 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 | return; | 356 | return; |
357 | } | 357 | } |
358 | 358 |
src/lib3270/globals.h
@@ -59,11 +59,9 @@ | @@ -59,11 +59,9 @@ | ||
59 | #include <libintl.h> | 59 | #include <libintl.h> |
60 | #define _( x ) gettext(x) | 60 | #define _( x ) gettext(x) |
61 | #define N_( x ) x | 61 | #define N_( x ) x |
62 | - #define MSG_( c, s ) gettext(s) | ||
63 | #else | 62 | #else |
64 | #define _( x ) x | 63 | #define _( x ) x |
65 | #define N_( x ) x | 64 | #define N_( x ) x |
66 | - #define MSG_( c, s ) s | ||
67 | #endif // HAVE_LIBINTL | 65 | #endif // HAVE_LIBINTL |
68 | 66 | ||
69 | 67 | ||
@@ -120,23 +118,24 @@ | @@ -120,23 +118,24 @@ | ||
120 | #undef X3270_MENUS | 118 | #undef X3270_MENUS |
121 | #endif /*]*/ | 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 | #define LOCAL_PROCESS 1 | 123 | #define LOCAL_PROCESS 1 |
126 | #include <termios.h> | 124 | #include <termios.h> |
127 | 125 | ||
128 | - #if defined(HAVE_PTY_H) /*[*/ | 126 | + #if defined(HAVE_PTY_H) |
129 | #include <pty.h> | 127 | #include <pty.h> |
130 | - #endif /*]*/ | 128 | + #endif |
131 | 129 | ||
132 | - #if defined(HAVE_LIBUTIL_H) /*[*/ | 130 | + #if defined(HAVE_LIBUTIL_H) |
133 | #include <libutil.h> | 131 | #include <libutil.h> |
134 | - #endif /*]*/ | 132 | + #endif |
135 | 133 | ||
136 | - #if defined(HAVE_UTIL_H) /*[*/ | 134 | + #if defined(HAVE_UTIL_H) |
137 | #include <util.h> | 135 | #include <util.h> |
138 | - #endif /*]*/ | ||
139 | -#endif /*]*/ | 136 | + #endif |
137 | +#endif | ||
138 | +*/ | ||
140 | 139 | ||
141 | /* Functions we may need to supply. */ | 140 | /* Functions we may need to supply. */ |
142 | #if defined(NEED_STRTOK_R) /*[*/ | 141 | #if defined(NEED_STRTOK_R) /*[*/ |
@@ -182,26 +181,28 @@ LIB3270_INTERNAL int children; | @@ -182,26 +181,28 @@ LIB3270_INTERNAL int children; | ||
182 | LIB3270_INTERNAL int dft_buffersize; | 181 | LIB3270_INTERNAL int dft_buffersize; |
183 | #endif /*]*/ | 182 | #endif /*]*/ |
184 | 183 | ||
185 | -LIB3270_INTERNAL char *efontname; | 184 | +// LIB3270_INTERNAL char *efontname; |
186 | LIB3270_INTERNAL Boolean ever_3270; | 185 | LIB3270_INTERNAL Boolean ever_3270; |
187 | LIB3270_INTERNAL Boolean exiting; | 186 | LIB3270_INTERNAL Boolean exiting; |
188 | 187 | ||
189 | -#if defined(X3270_DISPLAY) /*[*/ | 188 | +/* |
189 | +#if defined(X3270_DISPLAY) | ||
190 | LIB3270_INTERNAL Boolean *extended_3270font; | 190 | LIB3270_INTERNAL Boolean *extended_3270font; |
191 | LIB3270_INTERNAL Font *fid; | 191 | LIB3270_INTERNAL Font *fid; |
192 | LIB3270_INTERNAL Boolean *font_8bit; | 192 | LIB3270_INTERNAL Boolean *font_8bit; |
193 | -#endif /*]*/ | 193 | +#endif |
194 | +*/ | ||
194 | 195 | ||
195 | // LIB3270_INTERNAL Boolean flipped; | 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 | #if defined(X3270_DBCS) /*[*/ | 200 | #if defined(X3270_DBCS) /*[*/ |
200 | LIB3270_INTERNAL char *full_efontname_dbcs; | 201 | LIB3270_INTERNAL char *full_efontname_dbcs; |
201 | #endif /*]*/ | 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 | #if defined(X3270_DBCS) /*[*/ | 207 | #if defined(X3270_DBCS) /*[*/ |
207 | LIB3270_INTERNAL char *local_encoding; | 208 | LIB3270_INTERNAL char *local_encoding; |