tn5250j/src/org/tn5250j/framework/tn5250 ScreenPlanes.java,1.11,1.12
Christian Geisert <[email protected]> Fri, 09 Dec 2005 14:39:10 +0000
| Newsgroups | gmane.comp.java.tn5250j.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/tn5250j/tn5250j/src/org/tn5250j/framework/tn5250
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14634/src/org/tn5250j/framework/tn5250
Modified Files:
ScreenPlanes.java
Log Message:
Support for launching customized external program function via hotspot
Submitted by: Richard Houston <rhouston -(at)- rlhc.net>
Index: ScreenPlanes.java
===================================================================
RCS file: /cvsroot/tn5250j/tn5250j/src/org/tn5250j/framework/tn5250/ScreenPlanes.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** ScreenPlanes.java 8 Jul 2005 06:16:24 -0000 1.11
--- ScreenPlanes.java 9 Dec 2005 14:39:08 -0000 1.12
***************
*** 26,29 ****
--- 26,32 ----
package org.tn5250j.framework.tn5250;
+ import java.util.Properties;
+
+ import org.tn5250j.ExternalProgramConfig;
import org.tn5250j.TN5250jConstants;
***************
*** 1048,1051 ****
--- 1051,1083 ----
}
+ // now lets check for External Program: .
+ else if (!hs && x > 0 && x < lenScreen - 7 &&
+ screen[x - 1] <= ' ' &&
+ screenGUI[x] == NO_GUI &&
+ (screenExtended[x] & EXTENDED_5250_NON_DSP) == 0
+ ) {
+ Properties etnProps = ExternalProgramConfig.getInstance().getEtnPgmProps();
+ String count = etnProps.getProperty("etn.pgm.support.total.num");
+ if(count != null && count.length() > 0){
+ int total = Integer.parseInt(count);
+ for(int i=1;i<=total;i++){
+ String program = etnProps.getProperty("etn.pgm."+i+".command.name");
+ String key="";
+ if(x + program.length() >= screen.length) break;
+ for(int j=0;j<=program.length();j++){
+ key+=screen[x+j];
+ }
+ if(key.toLowerCase().equals(program.toLowerCase()+":")) {
+ hs = true;
+ screenGUI[x] = BUTTON_LEFT_EB;
+ while (screen[++x] > ' ') {
+ screenGUI[x] = BUTTON_MIDDLE_EB;
+ }
+ screenGUI[--x] = BUTTON_RIGHT_EB;
+ break;
+ }
+ }
+ }
+ }
else {
// now lets check for MAILTO: .
***************
*** 1076,1079 ****
--- 1108,1112 ----
}
}
+
if (!retHS && hs)
retHS = true;
-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems? Stop! Download the new AJAX search engine that makes
searching your log files as easy as surfing the web. DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click