home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Frozen Fish 1: Amiga
/
FrozenFish-Apr94.iso
/
bbs
/
alib
/
d5xx
/
d559
/
apig.lha
/
APIG
/
apiglib_v11.lzh
/
e5_menus.rexx
< prev
next >
Wrap
OS/2 REXX Batch file
|
1991-09-28
|
3KB
|
93 lines
/* */
x = addlib("apig.library",0,-30,0)
portname = "example5_port"
p = openport(portname)
call set_apig_globals()
scrtitle = "Hey Buddy, Yea You, This is Your New Screen !"
wintitle = "This is your title"
winidcmp = CLOSEWINDOW+MENUPICK
winflags = WINDOWCLOSE+WINDOWDEPTH+ACTIVATE
scr = openscreen(0,0,640,400,4,4,5,LACE+HIRES,CUSTOMSCREEN,scrtitle)
/* open window */
w1 = openwindow(portname,,,640,400,2,4,winidcmp,winflags,wintitle,scr,,,)
w1rptr = getwindowrastport(w1)
menu0 = makemenu(0,"MENU0",0,60,0,0)
item1 = makeitem(menu0,"Menu0 Item 1",menu0,0,0,0,0,0,0,0,1,0,jam2,0,0)
menu1 = makemenu(menu0,"MENU1",0,60,0,menu0)
item1 = makeitem(menu0,"Menu1 Item 1",menu1,0,0,0,0,0,0,0,1,0,jam2,0,0)
left = 50
menu2 = makemenu(menu0,"MENU2",0,60,0,menu0)
item1 = makeitem(menu0,"Menu2 Item 1",menu2,0,0,0,0,0,0,0,1,0,jam2,0,0)
sub1 = makesubitem(menu0,"SubItem1",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
sub2 = makesubitem(menu0,"SubItem2",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
call makesubitem(menu0,"SubItem3",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
menu3 = makemenu(menu0,"MENU3",0,60,0,menu0)
item1 = makeitem(menu0,"Menu3 Item 1",menu3,0,0,0,0,0,0,0,1,0,jam2,0,0)
menu4 = makemenu(menu0,"MENU4",0,60,0,menu0)
item1 = makeitem(menu0,"Menu4 Item 1",menu4,0,0,0,0,0,0,0,1,0,jam2,0,0)
item2 = makeitem(menu0,"Menu4 Item 2",menu4,0,0,0,0,0,0,0,1,0,jam2,0,0)
item3 = makeitem(menu0,"Menu4 Item 3",menu4,0,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu4 Item 4",menu4,0,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu4 Item 5",menu4,0,0,0,0,0,0,0,1,0,jam2,0,0)
menu5 = makemenu(menu0,"MENU5",0,60,0,menu0)
item1 = makeitem(menu0,"Menu5 Item1",menu5,0,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item2",menu5,0,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item3",menu5,0,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item4",menu5,100,65536,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item5",menu5,100,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item6",menu5,100,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item7",menu5,200,65536,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item8",menu5,200,0,0,0,0,0,0,1,0,jam2,0,0)
call makeitem(menu0,"Menu5 Item9",menu5,200,0,0,0,0,0,0,1,0,jam2,0,0)
sub1 = makesubitem(menu0,"SubItem1",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
sub2 = makesubitem(menu0,"SubItem2",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
call makesubitem(menu0,"SubItem3",item1,left,0,0,0,0,0,0,1,0,jam2,0,0)
x = setmenustrip(w1,menu0)
exitme = 0
z = pitext(w1rptr,200,80,"A Simple Menu Example",1,0,JAM2,0)
do forever
x = waitpkt(portname)
do forever
msg = '0000 0000'x
msg = getpkt(portname)
if msg = '0000 0000'x then leave
class = getarg(msg,0)
if class = CLOSEWINDOW then exitme = 1
x = reply(msg,0)
end
if exitme = 1 then leave
end
z = freemenu(menu0)
z = closewindow(w1)
z = closescreen(scr)
exit