Commit 2b74680a6841a2c608318d90112666afdfdeec66

Authored by perry.werneck@gmail.com
1 parent 0b463e02

Implementando versão android

android/jni/misc.cpp
@@ -44,3 +44,16 @@ JNIEXPORT jstring JNICALL Java_br_com_bb_pw3270_lib3270_getEncoding(JNIEnv *env, @@ -44,3 +44,16 @@ JNIEXPORT jstring JNICALL Java_br_com_bb_pw3270_lib3270_getEncoding(JNIEnv *env,
44 { 44 {
45 return env->NewStringUTF(lib3270_get_charset(lib3270_get_default_session_handle())); 45 return env->NewStringUTF(lib3270_get_charset(lib3270_get_default_session_handle()));
46 } 46 }
  47 +
  48 +JNIEXPORT void JNICALL Java_br_com_bb_pw3270_lib3270_setToggle(JNIEnv *env, jobject obj, jstring name, jboolean state)
  49 +{
  50 + LIB3270_TOGGLE id = lib3270_get_toggle_id(env->GetStringUTFChars(name, 0));
  51 +
  52 + session_request(env,obj);
  53 +
  54 + if(id >= 0)
  55 + lib3270_set_toggle(session,id,state ? 1 : 0);
  56 +
  57 + session_release();
  58 +
  59 +}
android/lib3270NDK.cbp
@@ -39,6 +39,9 @@ @@ -39,6 +39,9 @@
39 <Unit filename="../src/lib3270/html.c"> 39 <Unit filename="../src/lib3270/html.c">
40 <Option compilerVar="CC" /> 40 <Option compilerVar="CC" />
41 </Unit> 41 </Unit>
  42 + <Unit filename="../src/lib3270/kybd.c">
  43 + <Option compilerVar="CC" />
  44 + </Unit>
42 <Unit filename="../src/lib3270/selection.c"> 45 <Unit filename="../src/lib3270/selection.c">
43 <Option compilerVar="CC" /> 46 <Option compilerVar="CC" />
44 </Unit> 47 </Unit>
android/src/br/com/bb/pw3270/lib3270.java
@@ -33,6 +33,9 @@ public class lib3270 @@ -33,6 +33,9 @@ public class lib3270
33 33
34 lib3270() 34 lib3270()
35 { 35 {
  36 + setToggle("dstrace",true);
  37 + setToggle("screentrace",true);
  38 + setToggle("eventtrace",true);
36 changed = false; 39 changed = false;
37 mainloop = null; 40 mainloop = null;
38 } 41 }
@@ -358,6 +361,7 @@ public class lib3270 @@ -358,6 +361,7 @@ public class lib3270
358 public native String getEncoding(); 361 public native String getEncoding();
359 public native String getVersion(); 362 public native String getVersion();
360 public native String getRevision(); 363 public native String getRevision();
  364 + public native void setToggle(String name, boolean state);
361 365
362 // Network I/O 366 // Network I/O
363 public native void procRecvdata( byte[] data, int len); 367 public native void procRecvdata( byte[] data, int len);
@@ -5,7 +5,7 @@ msgid &quot;&quot; @@ -5,7 +5,7 @@ msgid &quot;&quot;
5 msgstr "" 5 msgstr ""
6 "Project-Id-Version: pw3270 5.0\n" 6 "Project-Id-Version: pw3270 5.0\n"
7 "Report-Msgid-Bugs-To: \n" 7 "Report-Msgid-Bugs-To: \n"
8 -"POT-Creation-Date: 2012-07-09 08:24-0300\n" 8 +"POT-Creation-Date: 2012-07-12 09:26-0300\n"
9 "PO-Revision-Date: 2012-06-21 11:08-0300\n" 9 "PO-Revision-Date: 2012-06-21 11:08-0300\n"
10 "Last-Translator: Perry Werneck <perry.werneck@gmail.com>\n" 10 "Last-Translator: Perry Werneck <perry.werneck@gmail.com>\n"
11 "Language-Team: Português do Brasil <>\n" 11 "Language-Team: Português do Brasil <>\n"
@@ -43,7 +43,7 @@ msgstr &quot;%s requer GTK versão %d.%d.%d&quot; @@ -43,7 +43,7 @@ msgstr &quot;%s requer GTK versão %d.%d.%d&quot;
43 msgid "%s: unknown family %d" 43 msgid "%s: unknown family %d"
44 msgstr "%s: Familia %d é inválida" 44 msgstr "%s: Familia %d é inválida"
45 45
46 -#: telnet.c:1067 46 +#: telnet.c:1083
47 #, c-format 47 #, c-format
48 msgid "%s:%d" 48 msgid "%s:%d"
49 msgstr "%s:%d" 49 msgstr "%s:%d"
@@ -90,7 +90,7 @@ msgstr &quot;&lt;%s&gt; precisa do atributo %s&quot; @@ -90,7 +90,7 @@ msgstr &quot;&lt;%s&gt; precisa do atributo %s&quot;
90 msgid "<%s> should be on toplevel" 90 msgid "<%s> should be on toplevel"
91 msgstr "<%s> deve estar no primeiro nível" 91 msgstr "<%s> deve estar no primeiro nível"
92 92
93 -#: telnet.c:3332 93 +#: telnet.c:3312
94 #, c-format 94 #, c-format
95 msgid "" 95 msgid ""
96 "<b>Connection state:</b> %s\n" 96 "<b>Connection state:</b> %s\n"
@@ -161,7 +161,7 @@ msgstr &quot;BLKSIZE:&quot; @@ -161,7 +161,7 @@ msgstr &quot;BLKSIZE:&quot;
161 msgid "Background" 161 msgid "Background"
162 msgstr "Fundo" 162 msgstr "Fundo"
163 163
164 -#: telnet.c:417 164 +#: telnet.c:418
165 msgid "Bad winsock version" 165 msgid "Bad winsock version"
166 msgstr "Versão winsock inválida" 166 msgstr "Versão winsock inválida"
167 167
@@ -189,6 +189,10 @@ msgstr &quot;Negrito&quot; @@ -189,6 +189,10 @@ msgstr &quot;Negrito&quot;
189 msgid "Brazilian Public Software Portal" 189 msgid "Brazilian Public Software Portal"
190 msgstr "Portal do Software Público Brasileiro" 190 msgstr "Portal do Software Público Brasileiro"
191 191
  192 +#: telnet.c:2037
  193 +msgid "Broken pipe"
  194 +msgstr "Broken pipe"
  195 +
192 #: dialog.c:99 196 #: dialog.c:99
193 msgid "C_haracter Coding:" 197 msgid "C_haracter Coding:"
194 msgstr "C_odificação de caracteres:" 198 msgstr "C_odificação de caracteres:"
@@ -206,12 +210,12 @@ msgstr &quot;At_ual&quot; @@ -206,12 +210,12 @@ msgstr &quot;At_ual&quot;
206 msgid "Can't accept unnamed %s" 210 msgid "Can't accept unnamed %s"
207 msgstr "Não posso aceitar elemento %s sem nome" 211 msgstr "Não posso aceitar elemento %s sem nome"
208 212
209 -#: telnet.c:699 213 +#: telnet.c:700
210 #, c-format 214 #, c-format
211 msgid "Can't connect to %s:%d" 215 msgid "Can't connect to %s:%d"
212 msgstr "Não foi possível conectar a %s:%d" 216 msgstr "Não foi possível conectar a %s:%d"
213 217
214 -#: host.c:315 218 +#: host.c:316
215 msgid "Can't connect to host" 219 msgid "Can't connect to host"
216 msgstr "Não foi possível conectar ao servidor" 220 msgstr "Não foi possível conectar ao servidor"
217 221
@@ -281,7 +285,7 @@ msgstr &quot;&quot; @@ -281,7 +285,7 @@ msgstr &quot;&quot;
281 "Não foi possível salvar a seleção para o arquivo\n" 285 "Não foi possível salvar a seleção para o arquivo\n"
282 "%s" 286 "%s"
283 287
284 -#: telnet.c:838 288 +#: telnet.c:839
285 msgid "Can't set SSL socket file descriptor" 289 msgid "Can't set SSL socket file descriptor"
286 msgstr "Não foi possível definir o descritor de socket SSL" 290 msgstr "Não foi possível definir o descritor de socket SSL"
287 291
@@ -301,7 +305,7 @@ msgstr &quot;Não foi possível iniciar transferência de arquivo&quot; @@ -301,7 +305,7 @@ msgstr &quot;Não foi possível iniciar transferência de arquivo&quot;
301 msgid "Can't start upload" 305 msgid "Can't start upload"
302 msgstr "Não foi possível iniciar upload" 306 msgstr "Não foi possível iniciar upload"
303 307
304 -#: telnet.c:418 308 +#: telnet.c:419
305 #, c-format 309 #, c-format
306 msgid "Can't use winsock version %d.%d" 310 msgid "Can't use winsock version %d.%d"
307 msgstr "Não é possível usar a Winsock versão %d.%d" 311 msgstr "Não é possível usar a Winsock versão %d.%d"
@@ -310,11 +314,11 @@ msgstr &quot;Não é possível usar a Winsock versão %d.%d&quot; @@ -310,11 +314,11 @@ msgstr &quot;Não é possível usar a Winsock versão %d.%d&quot;
310 msgid "Cancelled by user" 314 msgid "Cancelled by user"
311 msgstr "Cancelado pelo usuário" 315 msgstr "Cancelado pelo usuário"
312 316
313 -#: telnet.c:733 317 +#: telnet.c:734
314 msgid "Cannot create socket handle" 318 msgid "Cannot create socket handle"
315 msgstr "Não foi possível criar um manipulador de socket" 319 msgstr "Não foi possível criar um manipulador de socket"
316 320
317 -#: session.c:307 321 +#: session.c:309
318 #, c-format 322 #, c-format
319 msgid "Cannot find charset \"%s\", using defaults" 323 msgid "Cannot find charset \"%s\", using defaults"
320 msgstr "Não encontrei codificação \"%s\", usando defaults" 324 msgstr "Não encontrei codificação \"%s\", usando defaults"
@@ -347,10 +351,15 @@ msgstr &quot;Completo&quot; @@ -347,10 +351,15 @@ msgstr &quot;Completo&quot;
347 msgid "Connect on startup" 351 msgid "Connect on startup"
348 msgstr "Conectar ao iniciar" 352 msgstr "Conectar ao iniciar"
349 353
350 -#: telnet.c:838 telnet.c:856 354 +#: telnet.c:839 telnet.c:857
351 msgid "Connection failed" 355 msgid "Connection failed"
352 msgstr "Conexão falhou" 356 msgstr "Conexão falhou"
353 357
  358 +#: telnet.c:2041
  359 +#, fuzzy
  360 +msgid "Connection reset by peer"
  361 +msgstr "Ação falhou"
  362 +
354 #: ui/00default.xml:116 363 #: ui/00default.xml:116
355 msgid "Copy" 364 msgid "Copy"
356 msgstr "Copiar" 365 msgstr "Copiar"
@@ -416,7 +425,7 @@ msgstr &quot;Mostrar atualizações de janela&quot; @@ -416,7 +425,7 @@ msgstr &quot;Mostrar atualizações de janela&quot;
416 msgid "Default" 425 msgid "Default"
417 msgstr "Padrão" 426 msgstr "Padrão"
418 427
419 -#: telnet.c:1673 428 +#: telnet.c:1692
420 msgid "Device type rejected" 429 msgid "Device type rejected"
421 msgstr "Tipo de dispositivo rejeitado" 430 msgstr "Tipo de dispositivo rejeitado"
422 431
@@ -424,7 +433,7 @@ msgstr &quot;Tipo de dispositivo rejeitado&quot; @@ -424,7 +433,7 @@ msgstr &quot;Tipo de dispositivo rejeitado&quot;
424 msgid "Disconnected from host" 433 msgid "Disconnected from host"
425 msgstr "Desconectado do servidor" 434 msgstr "Desconectado do servidor"
426 435
427 -#: telnet.c:1266 436 +#: telnet.c:1285
428 msgid "EOR received when not in 3270 mode, ignored." 437 msgid "EOR received when not in 3270 mode, ignored."
429 msgstr "EOR recebido fora do modo 3270, ignorado." 438 msgstr "EOR recebido fora do modo 3270, ignorado."
430 439
@@ -432,15 +441,15 @@ msgstr &quot;EOR recebido fora do modo 3270, ignorado.&quot; @@ -432,15 +441,15 @@ msgstr &quot;EOR recebido fora do modo 3270, ignorado.&quot;
432 msgid "ET_A" 441 msgid "ET_A"
433 msgstr "ET_A" 442 msgstr "ET_A"
434 443
435 -#: host.c:339 444 +#: host.c:340
436 msgid "Empty LU name" 445 msgid "Empty LU name"
437 msgstr "Nome da LU está em branco" 446 msgstr "Nome da LU está em branco"
438 447
439 -#: host.c:266 host.c:393 448 +#: host.c:267 host.c:394
440 msgid "Empty hostname" 449 msgid "Empty hostname"
441 msgstr "Nome do host em branco" 450 msgstr "Nome do host em branco"
442 451
443 -#: host.c:446 452 +#: host.c:447
444 msgid "Empty port name" 453 msgid "Empty port name"
445 msgstr "Porta em branco" 454 msgstr "Porta em branco"
446 455
@@ -541,11 +550,11 @@ msgstr &quot;Servidor desconectou, transferência cancelada&quot; @@ -541,11 +550,11 @@ msgstr &quot;Servidor desconectou, transferência cancelada&quot;
541 msgid "Host is T_SO" 550 msgid "Host is T_SO"
542 msgstr "Servidor é T_SO" 551 msgstr "Servidor é T_SO"
543 552
544 -#: telnet.c:1661 553 +#: telnet.c:1680
545 msgid "Host rejected device type or request type" 554 msgid "Host rejected device type or request type"
546 msgstr "Host rejected device type or request type" 555 msgstr "Host rejected device type or request type"
547 556
548 -#: telnet.c:1671 557 +#: telnet.c:1690
549 msgid "Host rejected resource(s)" 558 msgid "Host rejected resource(s)"
550 msgstr "Host rejected resource(s)" 559 msgstr "Host rejected resource(s)"
551 560
@@ -553,8 +562,8 @@ msgstr &quot;Host rejected resource(s)&quot; @@ -553,8 +562,8 @@ msgstr &quot;Host rejected resource(s)&quot;
553 msgid "Host to connect" 562 msgid "Host to connect"
554 msgstr "Servidor a conectar" 563 msgstr "Servidor a conectar"
555 564
556 -#: host.c:314 host.c:339 host.c:351 host.c:377 host.c:389 host.c:393  
557 -#: host.c:446 host.c:461 565 +#: host.c:315 host.c:340 host.c:352 host.c:378 host.c:390 host.c:394
  566 +#: host.c:447 host.c:462
558 msgid "Hostname syntax error" 567 msgid "Hostname syntax error"
559 msgstr "Formato inválido no nome do servidor" 568 msgstr "Formato inválido no nome do servidor"
560 569
@@ -578,7 +587,7 @@ msgstr &quot;Intensificado/Protegido&quot; @@ -578,7 +587,7 @@ msgstr &quot;Intensificado/Protegido&quot;
578 msgid "Intensified/Unprotected" 587 msgid "Intensified/Unprotected"
579 msgstr "Intensificado/Desprotegido" 588 msgstr "Intensificado/Desprotegido"
580 589
581 -#: host.c:495 590 +#: host.c:496
582 msgid "Invalid (empty) hostname" 591 msgid "Invalid (empty) hostname"
583 msgstr "Nome do host é invalido (vazio)" 592 msgstr "Nome do host é invalido (vazio)"
584 593
@@ -602,7 +611,7 @@ msgstr &quot;LRECL:&quot; @@ -602,7 +611,7 @@ msgstr &quot;LRECL:&quot;
602 msgid "Misc colors" 611 msgid "Misc colors"
603 msgstr "Cores diversas" 612 msgstr "Cores diversas"
604 613
605 -#: host.c:389 614 +#: host.c:390
606 msgid "Missing ']'" 615 msgid "Missing ']'"
607 msgstr "Faltando ']'" 616 msgstr "Faltando ']'"
608 617
@@ -619,7 +628,7 @@ msgstr &quot;Só Maiúsculas&quot; @@ -619,7 +628,7 @@ msgstr &quot;Só Maiúsculas&quot;
619 msgid "Move action needs target & direction attributes" 628 msgid "Move action needs target & direction attributes"
620 msgstr "Ação \"move\" precisa dos atributos \"target\" e \"direction\"" 629 msgstr "Ação \"move\" precisa dos atributos \"target\" e \"direction\""
621 630
622 -#: host.c:461 631 +#: host.c:462
623 msgid "Multiple port names" 632 msgid "Multiple port names"
624 msgstr "Múltiplos nomes de porta" 633 msgstr "Múltiplos nomes de porta"
625 634
@@ -635,11 +644,11 @@ msgstr &quot;Mostarda&quot; @@ -635,11 +644,11 @@ msgstr &quot;Mostarda&quot;
635 msgid "N/A" 644 msgid "N/A"
636 msgstr "N/A" 645 msgstr "N/A"
637 646
638 -#: telnet.c:447 telnet.c:703 647 +#: telnet.c:448 telnet.c:704
639 msgid "Network error" 648 msgid "Network error"
640 msgstr "Erro de rede" 649 msgstr "Erro de rede"
641 650
642 -#: telnet.c:405 telnet.c:416 telnet.c:732 telnet.c:743 651 +#: telnet.c:406 telnet.c:417 telnet.c:733 telnet.c:744
643 msgid "Network startup error" 652 msgid "Network startup error"
644 msgstr "Erro ao iniciar a rede" 653 msgstr "Erro ao iniciar a rede"
645 654
@@ -679,7 +688,7 @@ msgstr &quot;Estado inválido na OIA&quot; @@ -679,7 +688,7 @@ msgstr &quot;Estado inválido na OIA&quot;
679 msgid "OIA status ok" 688 msgid "OIA status ok"
680 msgstr "Estado normal na OIA" 689 msgstr "Estado normal na OIA"
681 690
682 -#: host.c:316 691 +#: host.c:317
683 #, c-format 692 #, c-format
684 msgid "Option '%c:' is not supported" 693 msgid "Option '%c:' is not supported"
685 msgstr "Opção não suportada: '%c:'" 694 msgstr "Opção não suportada: '%c:'"
@@ -789,26 +798,33 @@ msgstr &quot;Reselecionar&quot; @@ -789,26 +798,33 @@ msgstr &quot;Reselecionar&quot;
789 msgid "Return" 798 msgid "Return"
790 msgstr "Return" 799 msgstr "Return"
791 800
792 -#: telnet.c:3330 801 +#: telnet.c:3310
793 msgid "SSL Connect error" 802 msgid "SSL Connect error"
794 msgstr "Erro na conexão SSL" 803 msgstr "Erro na conexão SSL"
795 804
796 -#: telnet.c:1050 805 +#: telnet.c:1066
797 msgid "SSL Error" 806 msgid "SSL Error"
798 msgstr "Erro SSL" 807 msgstr "Erro SSL"
799 808
800 -#: telnet.c:1050 809 +#: telnet.c:1066
801 msgid "SSL Read error" 810 msgid "SSL Read error"
802 msgstr "Erro de leitura SSL" 811 msgstr "Erro de leitura SSL"
803 812
804 -#: host.c:301 813 +#: host.c:302
805 msgid "SSL error" 814 msgid "SSL error"
806 msgstr "Erro SSL" 815 msgstr "Erro SSL"
807 816
808 -#: telnet.c:856 817 +#: telnet.c:857
809 msgid "SSL negotiation failed" 818 msgid "SSL negotiation failed"
810 msgstr "Negociação SSL falhou" 819 msgstr "Negociação SSL falhou"
811 820
  821 +#: telnet.c:2027
  822 +#, fuzzy, c-format
  823 +msgid ""
  824 +"SSL_write:\n"
  825 +"%s"
  826 +msgstr "write(%s): %s"
  827 +
812 #: ui/00default.xml:101 828 #: ui/00default.xml:101
813 msgid "Save copy" 829 msgid "Save copy"
814 msgstr "Salvar cópia" 830 msgstr "Salvar cópia"
@@ -913,11 +929,11 @@ msgstr &quot;Mostrar padrão de teste&quot; @@ -913,11 +929,11 @@ msgstr &quot;Mostrar padrão de teste&quot;
913 msgid "Smart paste" 929 msgid "Smart paste"
914 msgstr "Colar inteligente" 930 msgstr "Colar inteligente"
915 931
916 -#: telnet.c:1071 932 +#: telnet.c:1087
917 msgid "Socket read error" 933 msgid "Socket read error"
918 msgstr "Erro ao ler dados da rede" 934 msgstr "Erro ao ler dados da rede"
919 935
920 -#: telnet.c:2043 936 +#: telnet.c:2048
921 msgid "Socket write error" 937 msgid "Socket write error"
922 msgstr "Erro ao enviar dados para a rede" 938 msgstr "Erro ao enviar dados para a rede"
923 939
@@ -925,7 +941,7 @@ msgstr &quot;Erro ao enviar dados para a rede&quot; @@ -925,7 +941,7 @@ msgstr &quot;Erro ao enviar dados para a rede&quot;
925 msgid "Space allocation units" 941 msgid "Space allocation units"
926 msgstr "Space allocation units" 942 msgstr "Space allocation units"
927 943
928 -#: host.c:351 944 +#: host.c:352
929 msgid "Space in LU name" 945 msgid "Space in LU name"
930 msgstr "Espaço no nome da LU" 946 msgstr "Espaço no nome da LU"
931 947
@@ -941,7 +957,7 @@ msgstr &quot;T_otal&quot; @@ -941,7 +957,7 @@ msgstr &quot;T_otal&quot;
941 msgid "Terminal colors" 957 msgid "Terminal colors"
942 msgstr "Cores do terminal" 958 msgstr "Cores do terminal"
943 959
944 -#: host.c:377 960 +#: host.c:378
945 msgid "Text before '['" 961 msgid "Text before '['"
946 msgstr "Texto antes de '['" 962 msgstr "Texto antes de '['"
947 963
@@ -982,7 +998,7 @@ msgstr &quot;&quot; @@ -982,7 +998,7 @@ msgstr &quot;&quot;
982 "programa; se não, escreva para a Free Software Foundation, Inc., 59 Temple " 998 "programa; se não, escreva para a Free Software Foundation, Inc., 59 Temple "
983 "Place, Suite 330, Boston, MA, 02111-1307, USA" 999 "Place, Suite 330, Boston, MA, 02111-1307, USA"
984 1000
985 -#: host.c:303 1001 +#: host.c:304
986 #, c-format 1002 #, c-format
987 msgid "" 1003 msgid ""
988 "This version of %s was built without support for secure sockets layer (SSL)." 1004 "This version of %s was built without support for secure sockets layer (SSL)."
@@ -1032,7 +1048,7 @@ msgstr &quot;UTF-8&quot; @@ -1032,7 +1048,7 @@ msgstr &quot;UTF-8&quot;
1032 msgid "Uknown DFT Open type from host" 1048 msgid "Uknown DFT Open type from host"
1033 msgstr "Servidor enviou código de abertura DFT desconhecido" 1049 msgstr "Servidor enviou código de abertura DFT desconhecido"
1034 1050
1035 -#: host.c:302 1051 +#: host.c:303
1036 msgid "Unable to connect to secure hosts" 1052 msgid "Unable to connect to secure hosts"
1037 msgstr "Não é possível conectar em servidores seguros" 1053 msgstr "Não é possível conectar em servidores seguros"
1038 1054
@@ -1116,7 +1132,7 @@ msgstr &quot;&quot; @@ -1116,7 +1132,7 @@ msgstr &quot;&quot;
1116 "Servidor desconhecido:\n" 1132 "Servidor desconhecido:\n"
1117 "%s" 1133 "%s"
1118 1134
1119 -#: telnet.c:576 1135 +#: telnet.c:577
1120 #, c-format 1136 #, c-format
1121 msgid "Unknown passthru host: %s" 1137 msgid "Unknown passthru host: %s"
1122 msgstr "" 1138 msgstr ""
@@ -1128,12 +1144,12 @@ msgstr &quot;&quot; @@ -1128,12 +1144,12 @@ msgstr &quot;&quot;
1128 msgid "Unknown popup type \"%s\"" 1144 msgid "Unknown popup type \"%s\""
1129 msgstr "Tipo de popup \"%s\" não é conhecido" 1145 msgstr "Tipo de popup \"%s\" não é conhecido"
1130 1146
1131 -#: telnet.c:605 resolver.c:147 1147 +#: telnet.c:606 resolver.c:147
1132 #, c-format 1148 #, c-format
1133 msgid "Unknown port number or service: %s" 1149 msgid "Unknown port number or service: %s"
1134 msgstr "Número de porta ou serviço desconhecido: %s" 1150 msgstr "Número de porta ou serviço desconhecido: %s"
1135 1151
1136 -#: telnet.c:561 1152 +#: telnet.c:562
1137 msgid "Unsupported passthru host session" 1153 msgid "Unsupported passthru host session"
1138 msgstr "Unsupported passthru host session" 1154 msgstr "Unsupported passthru host session"
1139 1155
@@ -1158,11 +1174,11 @@ msgstr &quot;Versão %s - Revisão %s&quot; @@ -1158,11 +1174,11 @@ msgstr &quot;Versão %s - Revisão %s&quot;
1158 msgid "View Field Delimiters" 1174 msgid "View Field Delimiters"
1159 msgstr "View Field Delimiters" 1175 msgstr "View Field Delimiters"
1160 1176
1161 -#: telnet.c:744 1177 +#: telnet.c:745
1162 msgid "WSAEventSelect failed" 1178 msgid "WSAEventSelect failed"
1163 msgstr "WSAEventSelect falhou" 1179 msgstr "WSAEventSelect falhou"
1164 1180
1165 -#: telnet.c:406 1181 +#: telnet.c:407
1166 msgid "WSAStartup failed" 1182 msgid "WSAStartup failed"
1167 msgstr "WSAStartup falhou" 1183 msgstr "WSAStartup falhou"
1168 1184
@@ -1330,22 +1346,22 @@ msgstr &quot;um atributo \&quot;type\&quot; ou \&quot;group\&quot;&quot; @@ -1330,22 +1346,22 @@ msgstr &quot;um atributo \&quot;type\&quot; ou \&quot;group\&quot;&quot;
1330 msgid "an action attribute" 1346 msgid "an action attribute"
1331 msgstr "um atributo \"action\"" 1347 msgstr "um atributo \"action\""
1332 1348
1333 -#: telnet.c:3196 telnet.c:3207 1349 +#: telnet.c:3175 telnet.c:3186
1334 #, c-format 1350 #, c-format
1335 msgid "fcntl(%s)" 1351 msgid "fcntl(%s)"
1336 msgstr "fcntl(%s)" 1352 msgstr "fcntl(%s)"
1337 1353
1338 -#: telnet.c:3186 1354 +#: telnet.c:3165
1339 #, c-format 1355 #, c-format
1340 msgid "ioctl(%s)" 1356 msgid "ioctl(%s)"
1341 msgstr "ioctl(%s)" 1357 msgstr "ioctl(%s)"
1342 1358
1343 -#: telnet.c:654 telnet.c:660 telnet.c:667 1359 +#: telnet.c:655 telnet.c:661 telnet.c:668
1344 #, c-format 1360 #, c-format
1345 msgid "setsockopt(%s)" 1361 msgid "setsockopt(%s)"
1346 msgstr "setsockopt(%s)" 1362 msgstr "setsockopt(%s)"
1347 1363
1348 -#: telnet.c:647 1364 +#: telnet.c:648
1349 msgid "socket" 1365 msgid "socket"
1350 msgstr "socket" 1366 msgstr "socket"
1351 1367
@@ -1353,7 +1369,7 @@ msgstr &quot;socket&quot; @@ -1353,7 +1369,7 @@ msgstr &quot;socket&quot;
1353 msgid "translator-credits" 1369 msgid "translator-credits"
1354 msgstr "" 1370 msgstr ""
1355 1371
1356 -#: telnet.c:1046 1372 +#: telnet.c:1062
1357 msgid "unknown error" 1373 msgid "unknown error"
1358 msgstr "Erro desconhecido" 1374 msgstr "Erro desconhecido"
1359 1375
@@ -1387,15 +1403,8 @@ msgstr &quot;Erro desconhecido&quot; @@ -1387,15 +1403,8 @@ msgstr &quot;Erro desconhecido&quot;
1387 #~ msgid "The name of the default TCP port to connect" 1403 #~ msgid "The name of the default TCP port to connect"
1388 #~ msgstr "Nome da porta TCP para conectar" 1404 #~ msgstr "Nome da porta TCP para conectar"
1389 1405
1390 -#, fuzzy  
1391 -#~ msgid "Connection failed error"  
1392 -#~ msgstr "Ação falhou"  
1393 -  
1394 #~ msgid "Error \"%s\" reading local file (rc=%d)" 1406 #~ msgid "Error \"%s\" reading local file (rc=%d)"
1395 #~ msgstr "Error \"%s\" reading local file (rc=%d)" 1407 #~ msgstr "Error \"%s\" reading local file (rc=%d)"
1396 1408
1397 #~ msgid "Error \"%s\" writing to file (rc=%d)" 1409 #~ msgid "Error \"%s\" writing to file (rc=%d)"
1398 #~ msgstr "Error \"%s\" writing to file (rc=%d)" 1410 #~ msgstr "Error \"%s\" writing to file (rc=%d)"
1399 -  
1400 -#~ msgid "write(%s): %s"  
1401 -#~ msgstr "write(%s): %s"  
src/include/lib3270/session.h
@@ -274,7 +274,7 @@ @@ -274,7 +274,7 @@
274 274
275 // Session based callbacks 275 // Session based callbacks
276 int (*write)(H3270 *hSession, unsigned const char *buf, int len); 276 int (*write)(H3270 *hSession, unsigned const char *buf, int len);
277 - int (*disconnect)(H3270 *hSession); 277 + void (*disconnect)(H3270 *hSession);
278 278
279 void (*configure)(H3270 *session, unsigned short rows, unsigned short cols); 279 void (*configure)(H3270 *session, unsigned short rows, unsigned short cols);
280 void (*update)(H3270 *session, int baddr, unsigned char c, unsigned short attr, unsigned char cursor); 280 void (*update)(H3270 *session, int baddr, unsigned char c, unsigned short attr, unsigned char cursor);
src/lib3270/host.c
@@ -772,7 +772,7 @@ void lib3270_st_changed(H3270 *h, LIB3270_STATE tx, int mode) @@ -772,7 +772,7 @@ void lib3270_st_changed(H3270 *h, LIB3270_STATE tx, int mode)
772 772
773 for (st = h->st_callbacks[tx];st;st = st->next) 773 for (st = h->st_callbacks[tx];st;st = st->next)
774 { 774 {
775 - trace("st=%p func=%p",st,st->func); 775 +// trace("st=%p func=%p",st,st->func);
776 st->func(h,mode,st->data); 776 st->func(h,mode,st->data);
777 } 777 }
778 778
src/lib3270/kybd.c
@@ -171,7 +171,12 @@ static struct ta @@ -171,7 +171,12 @@ static struct ta
171 } *ta_head = (struct ta *) NULL, 171 } *ta_head = (struct ta *) NULL,
172 *ta_tail = (struct ta *) NULL; 172 *ta_tail = (struct ta *) NULL;
173 173
174 -#define ENQUEUE_ACTION(x) enq_ta(hSession, (void (*)(H3270 *, const char *, const char *)) x, NULL, NULL) 174 +
  175 +#if defined(DEBUG) || defined(ANDROID)
  176 + #define ENQUEUE_ACTION(x) enq_ta(hSession, (void (*)(H3270 *, const char *, const char *)) x, NULL, NULL, #x)
  177 +#else
  178 + #define ENQUEUE_ACTION(x) enq_ta(hSession, (void (*)(H3270 *, const char *, const char *)) x, NULL, NULL)
  179 +#endif // DEBUG
175 180
176 static const char dxl[] = "0123456789abcdef"; 181 static const char dxl[] = "0123456789abcdef";
177 #define FROM_HEX(c) (strchr(dxl, tolower(c)) - dxl) 182 #define FROM_HEX(c) (strchr(dxl, tolower(c)) - dxl)
@@ -250,15 +255,21 @@ static int enq_chk(H3270 *session) @@ -250,15 +255,21 @@ static int enq_chk(H3270 *session)
250 /* 255 /*
251 * Put an action on the typeahead queue. 256 * Put an action on the typeahead queue.
252 */ 257 */
  258 +#if defined(DEBUG) || defined(ANDROID)
  259 +static void enq_ta(H3270 *hSession, void (*fn)(H3270 *, const char *, const char *), const char *parm1, const char *parm2, const char *name)
  260 +#else
253 static void enq_ta(H3270 *hSession, void (*fn)(H3270 *, const char *, const char *), const char *parm1, const char *parm2) 261 static void enq_ta(H3270 *hSession, void (*fn)(H3270 *, const char *, const char *), const char *parm1, const char *parm2)
  262 +#endif // DEBUG
254 { 263 {
255 struct ta *ta; 264 struct ta *ta;
256 265
  266 + CHECK_SESSION_HANDLE(hSession);
  267 +
  268 + trace("%s: %s",__FUNCTION__,name);
  269 +
257 if(enq_chk(hSession)) 270 if(enq_chk(hSession))
258 return; 271 return;
259 272
260 - CHECK_SESSION_HANDLE(hSession);  
261 -  
262 ta = (struct ta *) lib3270_malloc(sizeof(*ta)); 273 ta = (struct ta *) lib3270_malloc(sizeof(*ta));
263 ta->session = hSession; 274 ta->session = hSession;
264 ta->next = (struct ta *) NULL; 275 ta->next = (struct ta *) NULL;
@@ -773,7 +784,13 @@ static Boolean key_Character(int code, Boolean with_ge, Boolean pasting, Boolean @@ -773,7 +784,13 @@ static Boolean key_Character(int code, Boolean with_ge, Boolean pasting, Boolean
773 char codename[64]; 784 char codename[64];
774 785
775 (void) sprintf(codename, "%d", code |(with_ge ? GE_WFLAG : 0) | (pasting ? PASTE_WFLAG : 0)); 786 (void) sprintf(codename, "%d", code |(with_ge ? GE_WFLAG : 0) | (pasting ? PASTE_WFLAG : 0));
  787 +
  788 +#if defined(DEBUG) || defined(ANDROID)
  789 + enq_ta(&h3270,key_Character_wrapper, codename, CN, "key_Character_wrapper");
  790 +#else
776 enq_ta(&h3270,key_Character_wrapper, codename, CN); 791 enq_ta(&h3270,key_Character_wrapper, codename, CN);
  792 +#endif // DEBUG
  793 +
777 return False; 794 return False;
778 } 795 }
779 baddr = h3270.cursor_addr; 796 baddr = h3270.cursor_addr;
@@ -1453,9 +1470,10 @@ LIB3270_KEY_ACTION( backtab ) @@ -1453,9 +1470,10 @@ LIB3270_KEY_ACTION( backtab )
1453 1470
1454 static void defer_unlock(H3270 *session) 1471 static void defer_unlock(H3270 *session)
1455 { 1472 {
  1473 + trace("%s",__FUNCTION__);
1456 kybdlock_clr(session,KL_DEFERRED_UNLOCK, "defer_unlock"); 1474 kybdlock_clr(session,KL_DEFERRED_UNLOCK, "defer_unlock");
1457 status_reset(session); 1475 status_reset(session);
1458 - if (CONNECTED) 1476 + if(CONNECTED)
1459 ps_process(); 1477 ps_process();
1460 } 1478 }
1461 1479
src/pw3270/v3270/iocallback.c
@@ -142,6 +142,7 @@ static void * static_AddTimeOut(unsigned long interval, H3270 *session, void (*p @@ -142,6 +142,7 @@ static void * static_AddTimeOut(unsigned long interval, H3270 *session, void (*p
142 t->fn = proc; 142 t->fn = proc;
143 t->session = session; 143 t->session = session;
144 144
  145 + trace("Adding timeout with %ld ms",interval);
145 g_timeout_add_full(G_PRIORITY_DEFAULT, (guint) interval, (GSourceFunc) do_timer, t, g_free); 146 g_timeout_add_full(G_PRIORITY_DEFAULT, (guint) interval, (GSourceFunc) do_timer, t, g_free);
146 147
147 return t; 148 return t;