home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ARM Club 3
/
TheARMClub_PDCD3.iso
/
hensa
/
filemanager
/
director_1
/
!Director
/
Utils
/
RunFilerAc
(
.txt
)
< prev
next >
Wrap
RISC OS BBC BASIC V Source
|
1995-08-04
|
2KB
|
66 lines
>RunFilerAc
(C) Nick Craig-Wood 1994
This is for starting off Filer_Action tasks
It expects <Dir> <Leaf> and <Path> to be set up
buffer_size%=1024
buffer% buffer_size%
$+" at "+
"OS_GetEnv"
env%
"OS_ReadArgs",",quit=load,/E,/G,value/E",env%,buffer%,buffer_size%
type%=
eval(buffer%!8)
gstrans(buffer%!12)
value%=
eval(buffer%!16)
type%=-1
1,"Syntax: *RunFilerAc <type> [<to>] [-value <bits>]"
"Wimp_Initialise",200,&4B534154,"RunFilerAction"
,taskID%
closedown:
$+" at "+
"Wimp_StartTask","Filer_Action"
handle%
"FilerAction_SendSelectedDirectory",handle%,
var("Dir")+
"FilerAction_SendSelectedFile",handle%,
var("Leaf")+
"OS_Byte",&A1,&C6
,,bits%
ebits% = ((bits%
&40) >> 6)
((bits%
&20) >> 4)
((bits%
&10) >> 2)
((bits%
&80) >> 4)
!buffer%=value%
value%=buffer%
to$=""
"FilerAction_SendStartOperation",handle%,type%,bits%,value%,4
"FilerAction_SendStartOperation",handle%,type%,bits%,to$+
(to$)+1
closedown
closedown
"Wimp_CloseDown"
var(var$)
a$,i$,len%
"OS_ReadVarVal",var$,buffer%,buffer_size%,0,3
,,len%
buffer%?len%=&D
=$buffer%
gstrans(p%)
i%,a$
p%=0
len%=(!p%)
&FFFF
a$=""
i%=2
2+len%-1
a$+=
(p%?i%)
eval(p%)
p%=0
C =p%!1