Commit bb4d9d9d43cb49a731d9037cf8fd48d0f5e8d546
1 parent
531efdd0
Exists in
master
and in
5 other branches
Iniciando implementação dos métodos no plugin rexx
Showing
3 changed files
with
38 additions
and
25 deletions
Show diff stats
pw3270.cbp
| ... | ... | @@ -232,13 +232,9 @@ |
| 232 | 232 | <Option compilerVar="CC" /> |
| 233 | 233 | </Unit> |
| 234 | 234 | <Unit filename="src/plugins/rx3270/Makefile.in" /> |
| 235 | - <Unit filename="src/plugins/rx3270/pluginmain.c"> | |
| 236 | - <Option compilerVar="CC" /> | |
| 237 | - </Unit> | |
| 235 | + <Unit filename="src/plugins/rx3270/pluginmain.cc" /> | |
| 238 | 236 | <Unit filename="src/plugins/rx3270/rx3270.h" /> |
| 239 | - <Unit filename="src/plugins/rx3270/rxapimain.c"> | |
| 240 | - <Option compilerVar="CC" /> | |
| 241 | - </Unit> | |
| 237 | + <Unit filename="src/plugins/rx3270/rxapimain.cc" /> | |
| 242 | 238 | <Unit filename="src/pw3270/Makefile.in" /> |
| 243 | 239 | <Unit filename="src/pw3270/actions.c"> |
| 244 | 240 | <Option compilerVar="CC" /> | ... | ... |
src/include/plugin.mak.in
| ... | ... | @@ -59,17 +59,17 @@ DLL_NAME=@DLLDIR@/@DLLPREFIX@$(MODULE_NAME)@DLLEXT@.@VERSION@ |
| 59 | 59 | PLUGIN_NAME=plugins/$(MODULE_NAME)@DLLEXT@ |
| 60 | 60 | |
| 61 | 61 | ifeq ($(LIB3270_MODE),Debug) |
| 62 | - PW3270_LIBS="-L$(BINDBG)@DLLDIR@ -l3270" | |
| 63 | - PW3270_CFLAGS="-I../../../src/include" | |
| 64 | - LIB3270_LIBS="-L$(BINDBG)@DLLDIR@ -l3270" | |
| 65 | - LIB270_CFLAGS="-I../../../src/include" | |
| 62 | + PW3270_LIBS=-L$(BINDBG)@DLLDIR@ -l3270 | |
| 63 | + PW3270_CFLAGS=-I../../../src/include | |
| 64 | + LIB3270_LIBS=-L$(BINDBG)@DLLDIR@ -l3270 | |
| 65 | + LIB270_CFLAGS=-I../../../src/include | |
| 66 | 66 | endif |
| 67 | 67 | |
| 68 | 68 | ifeq ($(LIB3270_MODE),Release) |
| 69 | - PW3270_LIBS="-L$(BINRLS)@DLLDIR@ -l3270" | |
| 70 | - PW3270_CFLAGS="-I../../../src/include" | |
| 71 | - LIB3270_LIBS="-L$(BINRLS)@DLLDIR@ -l3270" | |
| 72 | - LIB270_CFLAGS="-I../../../src/include" | |
| 69 | + PW3270_LIBS=-L$(BINRLS)@DLLDIR@ -l3270 | |
| 70 | + PW3270_CFLAGS=-I../../../src/include | |
| 71 | + LIB3270_LIBS=-L$(BINRLS)@DLLDIR@ -l3270 | |
| 72 | + LIB270_CFLAGS=-I../../../src/include | |
| 73 | 73 | endif |
| 74 | 74 | |
| 75 | 75 | ifeq ($(LIB3270_MODE),Default) | ... | ... |
src/plugins/rx3270/rxapimain.cc
| ... | ... | @@ -68,7 +68,7 @@ BOOL WINAPI DllMain(HANDLE hinst, DWORD dwcallpurpose, LPVOID lpvResvd) |
| 68 | 68 | |
| 69 | 69 | int librx3270_loaded(void) |
| 70 | 70 | { |
| 71 | - trace("%s %04x",__FUNCTION__,REXX_CURRENT_INTERPRETER_VERSION); | |
| 71 | + trace("%s %04x %s %s",__FUNCTION__,REXX_CURRENT_INTERPRETER_VERSION,__DATE__,__TIME__); | |
| 72 | 72 | return 0; |
| 73 | 73 | } |
| 74 | 74 | |
| ... | ... | @@ -80,27 +80,45 @@ int librx3270_unloaded(void) |
| 80 | 80 | |
| 81 | 81 | RexxRoutine0(CSTRING, rx3270version) |
| 82 | 82 | { |
| 83 | - return "Teste"; | |
| 83 | + return lib3270_get_version(); | |
| 84 | +} | |
| 85 | + | |
| 86 | +RexxRoutine0(CSTRING, rx3270QueryCState) | |
| 87 | +{ | |
| 88 | + return ""; | |
| 89 | +} | |
| 90 | + | |
| 91 | +RexxRoutine0(int, rx3270Disconnect) | |
| 92 | +{ | |
| 93 | + return 0; | |
| 94 | +} | |
| 95 | + | |
| 96 | +RexxRoutine2(int, rx3270Connect, CSTRING, hostname, int, timeout) | |
| 97 | +{ | |
| 98 | + return 0; | |
| 84 | 99 | } |
| 85 | 100 | |
| 86 | 101 | |
| 87 | 102 | // now build the actual entry list |
| 88 | 103 | RexxRoutineEntry rx3270_functions[] = |
| 89 | 104 | { |
| 90 | - REXX_TYPED_ROUTINE(rx3270version, rx3270version), | |
| 91 | - REXX_LAST_METHOD() | |
| 105 | + REXX_TYPED_ROUTINE(rx3270version, rx3270version), | |
| 106 | + REXX_TYPED_ROUTINE(rx3270QueryCState, rx3270QueryCState), | |
| 107 | + REXX_TYPED_ROUTINE(rx3270Disconnect, rx3270Disconnect), | |
| 108 | + REXX_TYPED_ROUTINE(rx3270Connect, rx3270Connect), | |
| 109 | + REXX_LAST_METHOD() | |
| 92 | 110 | }; |
| 93 | 111 | |
| 94 | 112 | RexxPackageEntry rx3270_package_entry = |
| 95 | 113 | { |
| 96 | 114 | STANDARD_PACKAGE_HEADER |
| 97 | - REXX_CURRENT_INTERPRETER_VERSION, // anything after 4.0.0 will work | |
| 98 | - "pw3270", // name of the package | |
| 99 | - "5.0", // package information | |
| 100 | - NULL, // no load/unload functions | |
| 115 | + REXX_CURRENT_INTERPRETER_VERSION, // anything after 4.0.0 will work | |
| 116 | + "pw3270", // name of the package | |
| 117 | + PACKAGE_VERSION, // package information | |
| 118 | + NULL, // no load/unload functions | |
| 101 | 119 | NULL, |
| 102 | - rx3270_functions, // the exported functions | |
| 103 | - NULL // no methods in rxmath. | |
| 120 | + rx3270_functions, // the exported functions | |
| 121 | + NULL // no methods in rx3270. | |
| 104 | 122 | }; |
| 105 | 123 | |
| 106 | 124 | // package loading stub. |
| ... | ... | @@ -111,7 +129,6 @@ OOREXX_GET_PACKAGE(rx3270); |
| 111 | 129 | BEGIN_EXTERN_C() |
| 112 | 130 | LIB3270_EXPORT RexxPackageEntry * RexxEntry RexxGetPackage(void) |
| 113 | 131 | { |
| 114 | - trace("%s struct size=%d ****************************************************",__FUNCTION__,(int) sizeof(RexxPackageEntry)); | |
| 115 | 132 | return &rx3270_package_entry; |
| 116 | 133 | } |
| 117 | 134 | END_EXTERN_C() | ... | ... |