home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ARM Club 3
/
TheARMClub_PDCD3.iso
/
hensa
/
filemanager
/
director_1
/
!Director
/
Menus
/
Files
/
MenuMenu
(
.txt
)
< prev
next >
Wrap
RISC OS BBC BASIC V Source
|
1995-07-27
|
4KB
|
149 lines
>Director:Menus.Files.MenuMenu
$+" at "+
MenuName$="MenuMenuMenu"
buffer_size%=1024
buffer% buffer_size%
%Menu=
swi_number("Director_Menu")
+EndMenu=
swi_number("Director_EndMenu")
)Option=
swi_number("Director_Option")
+Command=
swi_number("Director_Command")
%Dash=
swi_number("Director_Dash")
0XOS_ReadVarVal=
swi_number("XOS_ReadVarVal")
.XOS_SetVarVal=
swi_number("XOS_SetVarVal")
set("Director$Menu",MenuName$)
'Leaf$=
read("Director$CurrentLeaf")
Leaf$=""
*DirectorMouseDir x -file
*DirectorParsePath <x>
) Leaf$=
read("Director$CurrentLeaf")
Leaf$=""
'Path$=
read("Director$CurrentPath")
%Dir$=
read("Director$CurrentDir")
DirLeaf$=
leaf(Dir$)
set("Leaf",Leaf$)
set("Path",Path$)
set("Dir",Dir$)
"XOS_File",&17,Path$
,,,,,,Type%
Title$=Leaf$
Leaf$<>DirLeaf$
(DirLeaf$)<=3
Title$=DirLeaf$+"."+Title$
Menu,Title$+" "+MenuName$+" -temp"
Option,Title$+" -path "+Path$+" -up"
Type%<&1000
Type$="File"
Type$="Dir."
Option,""""+Type$+"
"+Leaf$+"
"" -sub ""Filer"""
*
Command,"Save:"+Path$
Dash
Option,"""Set CSD to
"+DirLeaf$+"
Command,"Dir "+Dir$
Option,"""Open
"+DirLeaf$+"
0(
Command,"Filer_OpenDir "+Dir$
Option,"""Pin
"+Leaf$+"
2G
Command,"SWI OS_Mouse TO x y|MPin "+Path$+" |<x>-90 |<y>+45"
Option,"AddTinyDir"
4&
Command,"AddTinyDir "+Path$
Option,"Command -sub *"
Path$<>Dir$
Type%>=&1000
Dash
Option,"""Set CSD to
"+Leaf$+"
Command,"Dir "+Path$
Option,"""Open
"+Leaf$+"
=)
Command,"Filer_OpenDir "+Path$
Type%<&1000
Dash
Option,"Filer_Run"
C%
Command,"Filer_Run "+Path$
Option,"Filer_Boot"
E&
Command,"Filer_Boot "+Path$
Option,"Edit"
G(
Command,"DirectorEdit "+Path$
Type%=&FFB
Option,"BasicEdit"
Command,"Fx 225 1|MSet a |<Key$0>|MKey 0 *Key 0 |<a>||MEDIT||M|MFx 138 0 128|MKey 4 |<0>|<&94>SYS""Wimp_CommandWindow"",-1||MQUIT||M|MDir "+Dir$+"|MBasic -load "+Leaf$
Option,"""Task window"" -sub ""Dynamic:/Director:Menus.Files.TaskArgs"""
MI
Command,"TaskWindow """+Path$+""" -display -quit -name "+Leaf$
Type%=&FF9
Dash
Option,"IconSprites"
S'
Command,"IconSprites "+Path$
Option,"ToolSprites"
U'
Command,"ToolSprites "+Path$
Option,"""BackDrop"" -sub ""Set BackDrop"""
W*
Command,"BackDrop -Tile "+Path$
Type%=&FEB
Dash
Option,"DirectorObey"
](
Command,"DirectorObey "+Path$
Option,"""DirectorObey -v"""
_C
Command,"TaskWindow ""DirectorObey -v "+Path$+""" -quit"
Option,"""Obey -v"""
a;
Command,"TaskWindow ""Obey -v "+Path$+""" -quit"
Dash
Option,"Memoriser -sub Memoriser:"
EndMenu
Menu,"""Copy Local"""
Option,""""+Leaf$+""" -len 32"
k<
Command,"/Director:Utils.RunFilerAc 7 <MenuText>"
EndMenu
Menu,"""Rename
"" Rename"
Option,""""+Leaf$+""" -len 32"
p9
Command,"Rename "+Path$+" "+Dir$+".<MenuText>"
EndMenu
swi_number(name$)
&39,,name$
read(a$)
?buffer%=13
XOS_ReadVarVal,a$,buffer%,buffer_size%,0,3
,,read%
buffer%?read%=13
=$buffer%
set(a$,v$)
XOS_SetVarVal,a$,v$,
v$,0,0
leaf(f$)
' l%=
l%-=1:
f$,l%,1)="."
f$,l%+1)