home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Enigma Amiga Life 109
/
EnigmaAmiga109CD.iso
/
software
/
sviluppo
/
rxmui
/
examples
/
z.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1999-12-21
|
5KB
|
196 lines
/* */
l="rmh.library";if ~show("L",l) then;if ~addlib(l,0,-30) then exit
if AddLibrary("rxmui.library")~=0 then exit
call rxmuiopt("DEBUGMODE SHOWERR")
call child("STRIP","MPROJECT","MENU")
mproject.Title="Project"
call child("MPROJECT",menuitem("MOPEN","Open...","O"))
call child("MPROJECT",menuitem("MSAVE","Save","S"))
call child("MPROJECT",menuitem("MSAVEAS","Save as...","W"))
call child("MPROJECT",menuitem("","BAR"))
call child("MPROJECT",menuitem("MABOUT","About...","?"))
call child("MPROJECT",menuitem("MABOUTMUI","About MUI..."))
call child("MPROJECT",menuitem("","BAR"))
call child("MPROJECT",menuitem("MHIDE","Hide","H"))
call child("MPROJECT",menuitem("","BAR"))
call child("MPROJECT",menuitem("MQUIT","Quit","Q"))
call child("STRIP","MEDITOR","MENU")
meditor.Title="Editor"
call child("MEDITOR",menuitem("MRESTORE","Restore","R"))
call child("STRIP","MPREFS","MENU")
mprefs.Title="Preferences"
call child("MPREFS",menuitem("MUSE","Use"))
call child("MPREFS",menuitem("MSAVE","Save"))
call child("MPREFS",menuitem("MMUI","Mui"))
res=NewObj("MENUSTRIP","STRIP")
if res~=0 then call err(res)
extra.Title="Extra"
call child("EXTRA",menuitem("UP","Up"))
call child("EXTRA",menuitem("DOWN","Down"))
call child("EXTRA",menuitem("EOL","Eol"))
res=NewObj("MENU","EXTRA")
if res~=0 then call err(res)
kk=menuitem("MLOVE","Lova","L")
app.Title="ShowHide"
app.Version="$VER: ShowHide 1.0 (22.11.99)"
app.Copyright="©1999, alfie"
app.Author="alfie"
app.Description="ShowHide show"
app.Base="SHOW"
app.SubWindow="WIN"
win.Title="ShowHide"
win.ID="SHOW"
win.userightborderscroller=1
win.usebottomborderscroller=1
win.Contents="MGROUP"
mgroup.0="BG"
bg.class="GROUP"
bg.horiz=1
bg.0 = Button("SORT","_Sort")
bg.1 = Button("REMOVE","_Remove")
mgroup.1="G"
g.class="GROUP"
g.horiz=1
g.0="LISTVIEW1"
listview1.class="NLISTVIEW"
listview1.list="LIST1"
list1.title="Uno|Due"
list1.titleclick=2
list1.DRAGSORTABLE=0
list1.dragtype="IMMEDIATE"
list1.multiselecte="DEFAULT"
list1.Format="BAR W=-1,BAR W=-1"
list1.mincolsortable=0
list1.titlemark=0
list1.0="Emi|Ranieri"
list1.1="Miriam|Fiocca"
list1.2="Camillo|Palmieri"
g.1="LISTVIEW2"
listview2.class="NLISTVIEW"
listview2.list="LIST2"
list2.dragsortable=1
list2.dragtype="IMMEDIATE"
list2.Format="COL=1 BAR,COL=0 BAR"
list2.dragsortinsert=1
list2.0="Alfonso Ranieri"
list2.1="Franco|Fiocca"
list2.2="Tiziana|Spognardi"
list2.3="Angelo|Barone"
mgroup.2="H"
h.class="GROUP"
h.horiz=1
h.0="S1"
s1.class="STRING"
s1.stringmaxlen=256
s1.multiline=0
s1.Styles=4
s1.isnumeric=0
s1.frame="STRING"
s1.draggable=1
s1.droppable=0
s1.disabled=0
h.1=Button("B1","Button1")
h.2=Button("B2","Button1")
h.3=CheckMark("C1")
h.4=String("S2")
res=NewObj("APPLICATION","APP")
if res~=0 then call err(res)
res=Notify("B1","PRESSED",0,"APP","RETURNID")
if res~=0 then call err(res)
res=Notify("LIST1","ACTIVE","EVERYTIME","APP","SETVAR","ACT")
if res~=0 then call err(res)
res=DandD("LIST2","LIST1","REMOVE")
if res~=0 then call err(res)
res=DandD("LIST1","LIST2")
if res~=0 then call err(res)
res=DandD("LIST1","S1")
if res~=0 then call err(res)
res=Notify("WIN","CLOSEREQUEST",1,"APP","RETURNID","QUIT")
if res~=0 then call err(res)
res=Notify("SORT","PRESSED",0,"LIST1","SORT")
if res~=0 then call err(res)
res=Notify("REMOVE","PRESSED",0,"LIST1","REMOVE","ACTIVE")
if res~=0 then call err(res)
res=Notify("REMOVE","PRESSED",0,"APP","RETURNID")
if res~=0 then call err(res)
res=Notify("LIST1","TITLECLICK","EVERYTIME","LIST1","SORT2","TRIGGERVALUE","ADD2VALUES")
if res~=0 then call err(res)
res=Notify("LIST1","SORTTYPE","EVERYTIME","LIST1","SET","TITLEMARK","TRIGGERVALUE")
res=set("LIST1","ACTIVE",0)
if res~=0 then call err(res)
res=Notify("LIST1","ACTIVE","EVERYTIME","LIST1","GETENTRY","ACTIVE","A")
if res~=0 then call err(res)
res=Notify("LIST1","ACTIVE","EVERYTIME","APP","RETURNID")
if res~=0 then call err(res)
res=Notify("C1","SELECTED","EVERYTIME","B1","SET","DISABLED","TRIGGERVALUE")
res=Notify("C1","SELECTED","EVERYTIME","B1","SET","DISABLED","TRIGGERVALUE")
res=Notify("C1","SELECTED","EVERYTIME","B1","SET","DISABLED","TRIGGERVALUE")
if res~=0 then call err(res)
res=Notify("C1","SELECTED","EVERYTIME","S2","SET","CONTENTS","Alfonso")
if res~=0 then call err(res)
res=set("WIN","OPEN",1)
if res~=0 then call err(res)
s=0
do forever
call handle("APP","H",s)
do i=0 to h.num-1
if h.i="QUIT" then exit
say h.num-1 h.i
if h.i=="B1" then do
say act
set("WIN","OPEN",0)
f.window="WIN"
f.SLEEPWINDOW=0
res=ReqFile("F")
if res~=0 then say getrxaslstring(res)
set("WIN","OPEN",1)
end
if h.i=="REMOVE" then do
res=set("WIN","OPEN",0)
if res~=0 then call err(res)
res=Dispose("B1")
if res~=0 then call err(res)
res=Dispose("S2")
if res~=0 then call err(res)
res=set("WIN","OPEN",1)
if res~=0 then call err(res)
end
end
s=Wait(or(h.signals,2**12))
if and(s,2**12)~=0 then exit
end
exit
err: procedure expose sigl rxmuierror
parse arg res
say signl "["res"]"
say getrxmuistring(res) "in line" sigl-1 rxmuierror
exit