GUI ScreenIO for Windows |
The first subroutine of each working-set does the flow-control for the entire set, so it's the most complex program of each working-set.
The rest of the subroutines in the working set simply worry about themselves.
When the user changes from this set to a different one (that was opened previously), you receive the event panel-EVENT-INACTIVATED. panel-ACTIVATED-PANEL-NAME will contain the name of the panel that is to be activated (the one that the user clicked), and panel-ACTIVATED-WORKING-SET contains the working-set of the panel which is to become active.
This routine simply moves the content of these fields to ACTIVE-PANEL and ACTIVE-SET, respectively, and then returns to the calling program.
Again, the main program will examines ACTIVE-SET to determine which subroutine needs to be called to activate the desired panel.
As we've said countless times before, don't do it. Calling GUI ScreenIO to redisplay a previously-displayed panel in the set will cause this one to be closed automatically. As you can see in the code below, you don't need to worry about it.
If the user clicks on the X box in the upper-right corner of the main panel, you will receive a panel-EVENT-CLOSE-AND-STOP.
The correct response is simply to set END-OF-JOB to TRUE, and return to the calling program.
IDENTIFICATION DIVISION.
|
© 2000-2019 Norcom, all rights reserved |