h25331
s 00001/00001/00057
d D 1.3 83/02/01 16:55:10 mjb 3 2
c fixed bug with hitting <ESC> in choice menus
e
s 00013/00001/00045
d D 1.2 83/01/21 19:15:29 tes 2 1
c Added erase/appear for graphic menus
e
s 00046/00000/00000
d D 1.1 83/01/20 11:15:33 tes 1 0
c date and time created 83/01/20 11:15:33 by tes
e
u
tes
mjb
U
t
T
I 1
subroutine selitm (id, item)
########################################################################
#                                                                      #
#          THIS MATERIAL IS CONFIDENTIAL AND IS FURNISHED UNDER        #
#          A WRITTEN LICENSE AGREEMENT.  IT MAY NOT BE USED,           #
#          COPIED OR DISCLOSED TO OTHERS EXCEPT IN ACCORDANCE          #
#          WITH THE TERMS OF THAT AGREEMENT.                           #
#                                                                      #
#          COPYRIGHT (C) 1982 GRAPHIC SOFTWARE SYSTEMS INC.            #
#          ALL RIGHTS RESERVED.                                        #
#                                                                      #
#     Function: Obtain a menu choice and manage menu data area         #
#                                                                      #
#     Input Parameters:                                                #
#            None                                                      #
#                                                                      #
#     Output Parameters:                                               #
#            id    - (integer) menu identification number              #
#            item  - (integer) menu item number                        #
#                                                                      #
#     Routines Called:                                                 #
#            None                                                      #
#                                                                      #
########################################################################
integer id, item

SHORTINT escape

include(`mnucom')

id = 0   # initially set the menu id to <null>
escape = ESC

repeat {
   if (dtamod == ON) {
I 2
      if (mnumod == ENTERxGRAPHICSxMODE) {
	 call erase
	 call apmesg (TOGGLExTOxDATA, 0)
	 call appear
         }
E 2
      call apmesg (TOGGLExTOxCHOICE, 0)
      call managd (escape)  # manage the data area
I 2
      if (mnumod == ENTERxGRAPHICSxMODE) {
	 call erase
	 call apmesg (TOGGLExTOxCHOICE, 0)
	 call appear
         }
E 2
      }
   else {
D 2
      if (crntid >= 100) call apmesg (TOGGLExTOxDATA, 0)
E 2
I 2
D 3
      if (crntid >= 100) {
E 3
I 3
      if (crntid >= 200) {
E 3
	 call apmesg (TOGGLExTOxDATA, 0)
	 }
E 2
      call selchc (id, item)   # select a choice from menu
      }
   } until (id > 0) #until a legal item is selected

return
end
E 1
