tn5250j/src/org/tn5250j My5250.java,1.38,1.39

"Kenneth J. Pouncey" <[email protected]> Fri, 30 Jul 2004 04:51:15 +0000
Newsgroups gmane.comp.java.tn5250j.cvs
Message-ID <[email protected]>
Update of /cvsroot/tn5250j/tn5250j/src/org/tn5250j
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31183/src/org/tn5250j

Modified Files:
	My5250.java 
Log Message:
Use new framework package and fix frame numbering problem 

Index: My5250.java
===================================================================
RCS file: /cvsroot/tn5250j/tn5250j/src/org/tn5250j/My5250.java,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -d -r1.38 -r1.39
*** My5250.java	26 Jul 2004 19:30:09 -0000	1.38
--- My5250.java	30 Jul 2004 04:51:13 -0000	1.39
***************
*** 42,45 ****
--- 42,47 ----
  import org.tn5250j.interfaces.GUIViewInterface;
  import org.tn5250j.interfaces.ConfigureFactory;
+ import org.tn5250j.framework.common.SessionManager;
+ import org.tn5250j.framework.common.Sessions;
  
  public class My5250 implements BootListener,TN5250jConstants,SessionListener,
***************
*** 562,571 ****
           sesProps.put(SESSION_HEART_BEAT,"1");
  
        Session5250 s2 = manager.openSession(sesProps,propFileName,sel);
        SessionGUI s = new SessionGUI(s2);
  
        if (!frame1.isVisible()) {
           splash.updateProgress(++step);
!          if (isSpecified("-noembed",args)) {
              newView();
           }
--- 564,583 ----
           sesProps.put(SESSION_HEART_BEAT,"1");
  
+       int sessionCount = manager.getSessions().getCount();
+ 
        Session5250 s2 = manager.openSession(sesProps,propFileName,sel);
        SessionGUI s = new SessionGUI(s2);
  
+ 
        if (!frame1.isVisible()) {
           splash.updateProgress(++step);
! 
!          // Here we check if this is the first session created in the system.
!          //  We have to create a frame on initialization for use in other scenarios
!          //  so if this is the first session being added in the system then we
!          //  use the frame that is created and skip the part of creating a new
!          //  view which would increment the count and leave us with an unused
!          //  frame.
!          if (isSpecified("-noembed",args) && sessionCount > 0) {
              newView();
           }



-------------------------------------------------------
This SF.Net email is sponsored by OSTG. Have you noticed the changes on
Linux.com, ITManagersJournal and NewsForge in the past few weeks? Now,
one more big change to announce. We are now OSTG- Open Source Technology
Group. Come see the changes on the new OSTG site. www.ostg.com