home *** CD-ROM | disk | FTP | other *** search
/ Carousel Volume 2 #1 / carousel.iso / mactosh / hc / openands.sit / NewFileName.p < prev    next >
MacBinary  |  1987-10-31  |  7.8 KB  |  [TEXT/MPS ]

open in: MacOS 8.1     |     Win98     |     DOS

view JSON data     |     view as text

This file was processed as: MacBinary (archive/macBinary).

You can browse this item here: NewFileName.p

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert ZX81 Sinclair BASIC (image/sinclairBASIC) ext Supported
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert bsdiff patch (other/bsdiffPatch) ext Unsupported
1% dexvert imgdiff patch (other/imgdiffPatch) ext Unsupported
1% dexvert WSUS Patch Storage File (other/wsusPatchStorageFile) ext Unsupported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Sat Oct 31 16:30:08 1987, modified Sat Oct 31 16:30:08 1987, creator 'MPS ', type ASCII, 7350 bytes "NewFileName.p" , at 0x1d36 382 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[MPS ]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0d 4e 65 77 46 69 6c | 65 4e 61 6d 65 2e 70 00 |..NewFil|eName.p.|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4d 50 53 | 20 01 00 00 00 00 00 00 |.TEXTMPS| .......|
|00000050| 00 00 00 00 00 1c b6 00 | 00 01 7e 9d b0 06 e0 9d |........|..~.....|
|00000060| b0 06 e0 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 c8 da 00 00 |........|........|
|00000080| 7b 24 52 2d 20 20 20 20 | 20 20 20 20 20 20 09 7d |{$R- | .}|
|00000090| 0d 7b 24 53 20 4e 65 77 | 46 69 6c 65 4e 61 6d 65 |.{$S New|FileName|
|000000a0| 20 7d 0d 0d 28 2a 2a 2a | 20 4e 65 77 20 46 69 6c | }..(***| New Fil|
|000000b0| 65 6e 61 6d 65 0d 0d 54 | 68 69 73 20 48 79 70 65 |ename..T|his Hype|
|000000c0| 72 43 61 72 64 20 58 46 | 75 6e 63 74 69 6f 6e 20 |rCard XF|unction |
|000000d0| 77 69 6c 6c 20 70 72 65 | 73 65 6e 74 20 74 68 65 |will pre|sent the|
|000000e0| 20 75 73 65 72 20 77 69 | 74 68 20 74 68 65 20 73 | user wi|th the s|
|000000f0| 74 61 6e 64 61 72 64 0d | 53 46 50 75 74 46 69 6c |tandard.|SFPutFil|
|00000100| 65 20 64 69 61 6c 6f 67 | 20 62 6f 78 20 61 6e 64 |e dialog| box and|
|00000110| 20 72 65 74 75 72 6e 20 | 74 68 65 20 75 73 65 72 | return |the user|
|00000120| 73 20 72 65 73 70 6f 6e | 63 65 20 74 6f 20 74 68 |s respon|ce to th|
|00000130| 65 20 63 61 6c 6c 65 72 | 0d 61 73 20 65 69 74 68 |e caller|.as eith|
|00000140| 65 72 20 61 20 66 75 6c | 6c 20 70 61 74 68 20 6e |er a ful|l path n|
|00000150| 61 6d 65 20 6f 66 20 74 | 68 65 20 6e 65 77 20 66 |ame of t|he new f|
|00000160| 69 6c 65 20 6f 72 20 65 | 6d 70 74 79 20 69 66 20 |ile or e|mpty if |
|00000170| 63 61 6e 63 65 6c 65 64 | 2e 0d 0d 49 20 68 61 76 |canceled|...I hav|
|00000180| 65 20 64 65 70 61 72 74 | 65 64 20 66 72 6f 6d 20 |e depart|ed from |
|00000190| 74 68 65 20 68 75 6d 61 | 6e 20 69 6e 74 65 72 66 |the huma|n interf|
|000001a0| 61 63 65 20 67 75 69 64 | 65 6c 69 6e 65 73 20 66 |ace guid|elines f|
|000001b0| 6f 72 20 64 69 61 6c 6f | 67 0d 62 6f 78 65 73 20 |or dialo|g.boxes |
|000001c0| 61 73 20 74 68 65 20 53 | 46 50 75 74 46 69 6c 65 |as the S|FPutFile|
|000001d0| 20 64 69 61 6c 6f 67 20 | 77 69 6c 6c 20 62 65 20 | dialog |will be |
|000001e0| 63 65 6e 74 65 72 65 64 | 20 69 6e 20 74 68 65 20 |centered| in the |
|000001f0| 68 79 70 65 72 63 61 72 | 64 0d 77 69 6e 64 6f 77 |hypercar|d.window|
|00000200| 20 61 6e 64 20 6e 6f 74 | 20 74 68 65 20 73 63 72 | and not| the scr|
|00000210| 65 65 6e 2e 20 20 4d 79 | 20 72 65 73 6f 6e 20 66 |een. My| reson f|
|00000220| 6f 72 20 74 68 69 73 20 | 69 73 20 74 68 61 74 20 |or this |is that |
|00000230| 48 79 70 65 72 43 61 72 | 64 20 0d 68 61 73 20 6f |HyperCar|d .has o|
|00000240| 6e 6c 79 20 6f 6e 65 20 | 77 69 6e 64 6f 77 20 28 |nly one |window (|
|00000250| 69 67 6e 6f 72 69 6e 67 | 20 6d 65 73 73 61 67 65 |ignoring| message|
|00000260| 20 62 6f 78 2c 20 26 63 | 29 20 77 69 74 68 69 6e | box, &c|) within|
|00000270| 20 77 68 69 63 68 20 6d | 61 6e 79 0d 6f 66 20 74 | which m|any.of t|
|00000280| 68 65 20 72 75 6c 65 73 | 20 61 72 65 20 62 72 6f |he rules| are bro|
|00000290| 6b 65 6e 20 73 6f 20 62 | 79 20 70 6c 61 63 69 6e |ken so b|y placin|
|000002a0| 67 20 74 68 65 20 64 69 | 61 6c 6f 67 20 63 65 6e |g the di|alog cen|
|000002b0| 74 65 72 65 64 20 6f 6e | 20 74 68 65 0d 77 69 6e |tered on| the.win|
|000002c0| 64 6f 77 20 69 74 20 63 | 6c 65 61 72 6c 79 20 69 |dow it c|learly i|
|000002d0| 6e 64 69 63 61 74 65 73 | 20 74 68 65 20 64 69 61 |ndicates| the dia|
|000002e0| 6c 6f 67 20 68 61 73 20 | 62 65 65 6e 20 70 72 65 |log has |been pre|
|000002f0| 73 65 6e 74 65 64 20 64 | 6f 20 74 6f 20 0d 70 72 |sented d|o to .pr|
|00000300| 65 73 73 69 6e 67 20 61 | 20 62 75 74 74 6f 6e 2e |essing a| button.|
|00000310| 0d 09 0d 4d 75 63 68 20 | 6f 66 20 74 68 65 20 63 |...Much |of the c|
|00000320| 6f 64 65 20 69 73 20 61 | 20 74 61 6b 65 6e 20 66 |ode is a| taken f|
|00000330| 72 6f 6d 20 74 68 65 20 | 46 69 6c 65 4e 61 6d 65 |rom the |FileName|
|00000340| 20 58 46 75 6e 63 74 69 | 6f 6e 20 62 79 0d 09 0d | XFuncti|on by...|
|00000350| 09 53 74 65 76 65 20 4d | 61 6c 6c 65 72 0d 09 41 |.Steve M|aller..A|
|00000360| 70 70 6c 65 20 43 6f 6d | 70 75 74 65 72 20 54 72 |pple Com|puter Tr|
|00000370| 61 69 6e 69 6e 67 20 53 | 75 70 70 6f 72 74 0d 09 |aining S|upport..|
|00000380| 43 6f 70 79 72 69 67 68 | 74 20 a9 20 31 39 38 37 |Copyrigh|t . 1987|
|00000390| 20 41 70 70 6c 65 20 43 | 6f 6d 70 75 74 65 72 0d | Apple C|omputer.|
|000003a0| 09 41 70 70 6c 65 4c 69 | 6e 6b 3a 20 4d 41 4c 4c |.AppleLi|nk: MALL|
|000003b0| 45 52 31 0d 0d 54 6f 20 | 63 6f 6d 70 69 6c 65 20 |ER1..To |compile |
|000003c0| 61 6e 64 20 6c 69 6e 6b | 20 77 69 74 68 20 4d 50 |and link| with MP|
|000003d0| 57 20 61 6e 64 20 4d 50 | 57 20 50 61 73 63 61 6c |W and MP|W Pascal|
|000003e0| 0d 09 0d 09 70 61 73 63 | 61 6c 20 2d 77 20 4e 65 |....pasc|al -w Ne|
|000003f0| 77 46 69 6c 65 4e 61 6d | 65 2e 70 0d 09 0d 09 6c |wFileNam|e.p....l|
|00000400| 69 6e 6b 20 2d 6d 20 45 | 4e 54 52 59 50 4f 49 4e |ink -m E|NTRYPOIN|
|00000410| 54 20 0d 09 09 20 2d 72 | 74 20 58 46 43 4e 3d 30 |T ... -r|t XFCN=0|
|00000420| 20 0d 09 09 20 2d 73 6e | 20 4d 61 69 6e 3d 4e 65 | ... -sn| Main=Ne|
|00000430| 77 46 69 6c 65 4e 61 6d | 65 20 0d 09 09 20 2d 6f |wFileNam|e ... -o|
|00000440| 20 48 79 70 65 72 43 6f | 6d 6d 61 6e 64 73 0d 09 | HyperCo|mmands..|
|00000450| 09 20 4e 65 77 46 69 6c | 65 4e 61 6d 65 2e 70 2e |. NewFil|eName.p.|
|00000460| 6f 0d 09 09 20 49 6e 74 | 65 72 66 61 63 65 2e 6f |o... Int|erface.o|
|00000470| 09 09 09 20 0d 09 09 20 | 50 61 73 6c 69 62 2e 6f |... ... |Paslib.o|
|00000480| 0d 0d 41 20 74 79 70 69 | 63 61 6c 20 48 79 70 65 |..A typi|cal Hype|
|00000490| 72 54 61 6c 6b 20 73 63 | 72 69 70 74 20 63 61 6c |rTalk sc|ript cal|
|000004a0| 6c 69 6e 67 20 4e 65 77 | 46 69 6c 65 4e 61 6d 65 |ling New|FileName|
|000004b0| 20 77 6f 75 6c 64 20 62 | 65 0d 0d 09 2d 2d 20 66 | would b|e...-- f|
|000004c0| 75 6e 63 74 69 6f 6e 20 | 4e 65 77 46 69 6c 65 4e |unction |NewFileN|
|000004d0| 61 6d 65 28 20 3c 70 72 | 6f 6d 70 74 3e 2c 20 3c |ame( <pr|ompt>, <|
|000004e0| 69 6e 69 74 69 61 6c 20 | 66 69 6c 65 6e 61 6d 65 |initial |filename|
|000004f0| 3e 20 29 3a 20 3c 66 69 | 6c 65 6e 61 6d 65 3e 0d |> ): <fi|lename>.|
|00000500| 0d 09 6f 6e 20 6d 6f 75 | 73 65 55 70 0d 09 09 70 |..on mou|seUp...p|
|00000510| 75 74 20 4e 65 77 46 69 | 6c 65 4e 61 6d 65 28 20 |ut NewFi|leName( |
|00000520| 22 53 61 76 65 20 66 69 | 65 6c 64 20 61 73 3f 22 |"Save fi|eld as?"|
|00000530| 2c 20 74 68 65 20 6e 61 | 6d 65 20 6f 66 20 66 69 |, the na|me of fi|
|00000540| 65 6c 64 20 78 20 29 20 | 69 6e 74 6f 20 66 69 6c |eld x ) |into fil|
|00000550| 65 6e 61 6d 65 0d 09 09 | 09 0d 09 09 69 66 20 66 |ename...|....if f|
|00000560| 69 6c 65 6e 61 6d 65 20 | 69 73 20 6e 6f 74 20 65 |ilename |is not e|
|00000570| 6d 70 74 79 20 74 68 65 | 6e 0d 09 09 09 6f 70 65 |mpty the|n....ope|
|00000580| 6e 20 66 69 6c 65 20 66 | 69 6c 65 6e 61 6d 65 0d |n file f|ilename.|
|00000590| 09 09 09 77 72 69 74 65 | 20 66 69 65 6c 64 20 78 |...write| field x|
|000005a0| 20 74 6f 20 66 69 6c 65 | 20 66 69 6c 65 6e 61 6d | to file| filenam|
|000005b0| 65 0d 09 09 09 63 6c 6f | 73 65 20 66 69 6c 65 20 |e....clo|se file |
|000005c0| 66 69 6c 65 6e 61 6d 65 | 0d 09 09 65 6e 64 20 69 |filename|...end i|
|000005d0| 66 0d 09 65 6e 64 20 6d | 6f 75 73 65 44 6f 77 6e |f..end m|ouseDown|
|000005e0| 0d 09 0d 57 72 69 74 74 | 65 6e 20 62 79 0d 09 0d |...Writt|en by...|
|000005f0| 09 41 6e 64 72 65 77 20 | 47 69 6c 6d 61 72 74 69 |.Andrew |Gilmarti|
|00000600| 6e 0d 09 41 63 61 64 65 | 6d 69 63 20 26 20 55 73 |n..Acade|mic & Us|
|00000610| 65 72 20 53 65 72 76 69 | 63 65 73 2c 20 42 6f 78 |er Servi|ces, Box|
|00000620| 20 31 38 38 35 0d 09 42 | 72 6f 77 6e 20 55 6e 69 | 1885..B|rown Uni|
|00000630| 76 65 72 73 69 74 79 0d | 09 50 72 6f 76 69 64 65 |versity.|.Provide|
|00000640| 6e 63 65 2c 20 52 68 6f | 64 65 20 49 73 6c 61 6e |nce, Rho|de Islan|
|00000650| 64 20 30 32 39 31 32 0d | 09 43 6f 70 79 72 69 67 |d 02912.|.Copyrig|
|00000660| 68 74 20 a9 20 31 39 38 | 37 20 42 72 6f 77 6e 20 |ht . 198|7 Brown |
|00000670| 55 6e 69 76 65 72 73 69 | 74 79 0d 09 62 69 74 6e |Universi|ty..bitn|
|00000680| 65 74 3a 20 20 41 4e 44 | 52 45 57 40 42 52 4f 57 |et: AND|REW@BROW|
|00000690| 4e 56 4d 0d 09 09 0d 09 | 4f 63 74 6f 62 65 72 20 |NVM.....|October |
|000006a0| 33 31 2c 20 31 39 38 37 | 20 2a 2a 2a 29 0d 0d 0d |31, 1987| ***)...|
|000006b0| 75 6e 69 74 20 6e 65 77 | 66 69 6c 65 6e 61 6d 65 |unit new|filename|
|000006c0| 55 6e 69 74 3b 0d 0d 09 | 69 6e 74 65 72 66 61 63 |Unit;...|interfac|
|000006d0| 65 0d 0d 09 09 75 73 65 | 73 20 6d 65 6d 74 79 70 |e....use|s memtyp|
|000006e0| 65 73 2c 20 71 75 69 63 | 6b 64 72 61 77 2c 20 6f |es, quic|kdraw, o|
|000006f0| 73 69 6e 74 66 2c 20 74 | 6f 6f 6c 69 6e 74 66 2c |sintf, t|oolintf,|
|00000700| 20 70 61 63 6b 69 6e 74 | 66 2c 20 68 79 70 65 72 | packint|f, hyper|
|00000710| 78 63 6d 64 3b 0d 0d 09 | 09 70 72 6f 63 65 64 75 |xcmd;...|.procedu|
|00000720| 72 65 20 65 6e 74 72 79 | 70 6f 69 6e 74 28 70 61 |re entry|point(pa|
|00000730| 72 61 6d 70 74 72 3a 20 | 78 63 6d 64 70 74 72 29 |ramptr: |xcmdptr)|
|00000740| 3b 0d 0d 09 69 6d 70 6c | 65 6d 65 6e 74 61 74 69 |;...impl|ementati|
|00000750| 6f 6e 0d 0d 09 09 70 72 | 6f 63 65 64 75 72 65 20 |on....pr|ocedure |
|00000760| 6e 65 77 66 69 6c 65 6e | 61 6d 65 28 70 61 72 61 |newfilen|ame(para|
|00000770| 6d 70 74 72 3a 20 78 63 | 6d 64 70 74 72 29 3b 20 |mptr: xc|mdptr); |
|00000780| 66 6f 72 77 61 72 64 3b | 0d 0d 09 09 70 72 6f 63 |forward;|....proc|
|00000790| 65 64 75 72 65 20 65 6e | 74 72 79 70 6f 69 6e 74 |edure en|trypoint|
|000007a0| 28 70 61 72 61 6d 70 74 | 72 3a 20 78 63 6d 64 70 |(parampt|r: xcmdp|
|000007b0| 74 72 29 3b 0d 09 09 62 | 65 67 69 6e 0d 09 09 09 |tr);...b|egin....|
|000007c0| 6e 65 77 66 69 6c 65 6e | 61 6d 65 28 70 61 72 61 |newfilen|ame(para|
|000007d0| 6d 70 74 72 29 3b 0d 09 | 09 65 6e 64 28 2a 20 65 |mptr);..|.end(* e|
|000007e0| 6e 74 72 79 20 70 6f 69 | 6e 74 20 2a 29 3b 0d 09 |ntry poi|nt *);..|
|000007f0| 09 0d 09 09 70 72 6f 63 | 65 64 75 72 65 20 6e 65 |....proc|edure ne|
|00000800| 77 66 69 6c 65 6e 61 6d | 65 3b 0d 0d 09 09 09 76 |wfilenam|e;.....v|
|00000810| 61 72 20 66 75 6c 6c 70 | 61 74 68 6e 61 6d 65 3a |ar fullp|athname:|
|00000820| 20 73 74 72 32 35 35 3b | 0d 09 09 09 09 66 69 6c | str255;|.....fil|
|00000830| 65 6e 61 6d 65 09 3a 20 | 73 74 72 32 35 35 3b 0d |ename.: |str255;.|
|00000840| 09 09 09 09 70 72 6f 6d | 70 74 09 09 3a 20 73 74 |....prom|pt..: st|
|00000850| 72 32 35 35 3b 0d 09 09 | 09 09 72 65 70 6c 79 09 |r255;...|..reply.|
|00000860| 09 3a 20 73 66 72 65 70 | 6c 79 3b 0d 0d 09 09 09 |.: sfrep|ly;.....|
|00000870| 7b 24 49 20 78 63 6d 64 | 67 6c 75 65 2e 69 6e 63 |{$I xcmd|glue.inc|
|00000880| 20 7d 0d 0d 0d 09 09 09 | 28 2a 2a 09 50 61 72 61 | }......|(**.Para|
|00000890| 6d 20 54 6f 20 4e 75 6d | 0d 09 09 0d 09 09 09 54 |m To Num|.......T|
|000008a0| 68 69 73 20 66 75 6e 63 | 74 69 6f 6e 20 72 65 74 |his func|tion ret|
|000008b0| 75 72 6e 73 20 61 20 6c | 6f 6e 67 20 69 6e 74 65 |urns a l|ong inte|
|000008c0| 67 65 72 20 69 6e 74 65 | 72 70 72 65 74 61 74 69 |ger inte|rpretati|
|000008d0| 6f 6e 20 6f 66 20 0d 09 | 09 09 61 20 7a 65 72 6f |on of ..|..a zero|
|000008e0| 20 74 65 72 6d 69 6e 61 | 74 65 64 20 73 74 72 69 | termina|ted stri|
|000008f0| 6e 67 20 28 63 2d 73 74 | 72 69 6e 67 29 2e 20 2a |ng (c-st|ring). *|
|00000900| 2a 29 0d 09 09 09 0d 09 | 09 09 66 75 6e 63 74 69 |*)......|..functi|
|00000910| 6f 6e 20 70 61 72 61 6d | 74 6f 6e 75 6d 28 20 70 |on param|tonum( p|
|00000920| 61 72 61 6d 3a 20 68 61 | 6e 64 6c 65 20 29 3a 20 |aram: ha|ndle ): |
|00000930| 6c 6f 6e 67 49 6e 74 3b | 0d 09 09 09 09 76 61 72 |longInt;|.....var|
|00000940| 20 53 74 72 3a 20 53 74 | 72 32 35 35 3b 0d 09 09 | Str: St|r255;...|
|00000950| 09 62 65 67 69 6e 0d 09 | 09 09 09 7a 65 72 6f 74 |.begin..|...zerot|
|00000960| 6f 70 61 73 28 20 70 61 | 72 61 6d 5e 2c 20 73 74 |opas( pa|ram^, st|
|00000970| 72 20 29 3b 0d 09 09 09 | 09 70 61 72 61 6d 74 6f |r );....|.paramto|
|00000980| 6e 75 6d 20 3a 3d 20 73 | 74 72 74 6f 6e 75 6d 28 |num := s|trtonum(|
|00000990| 20 73 74 72 20 29 0d 09 | 09 09 65 6e 64 28 2a 20 | str )..|..end(* |
|000009a0| 50 61 72 61 6d 54 6f 4e | 75 6d 20 2a 29 3b 0d 09 |ParamToN|um *);..|
|000009b0| 09 09 0d 0d 09 09 09 28 | 2a 2a 20 20 43 65 6e 74 |.......(|** Cent|
|000009c0| 65 72 52 65 63 74 0d 09 | 09 09 0d 09 09 09 54 68 |erRect..|......Th|
|000009d0| 69 73 20 66 75 6e 63 74 | 69 6f 6e 20 77 69 6c 6c |is funct|ion will|
|000009e0| 20 72 65 74 75 72 6e 20 | 74 68 65 20 70 6f 69 6e | return |the poin|
|000009f0| 74 20 77 68 65 72 65 20 | 74 68 65 20 74 6f 70 20 |t where |the top |
|00000a00| 6c 65 66 74 20 63 6f 72 | 6e 65 72 0d 09 09 09 6f |left cor|ner....o|
|00000a10| 66 20 69 6e 73 69 64 65 | 20 72 65 63 74 61 6e 67 |f inside| rectang|
|00000a20| 65 20 73 68 6f 75 6c 64 | 20 62 65 20 70 6c 61 63 |e should| be plac|
|00000a30| 65 64 20 69 6e 6f 72 64 | 65 72 20 66 6f 72 20 69 |ed inord|er for i|
|00000a40| 74 20 74 6f 20 62 65 0d | 09 09 09 63 65 6e 74 65 |t to be.|...cente|
|00000a50| 72 65 64 20 77 69 74 68 | 69 6e 20 6f 75 74 73 69 |red with|in outsi|
|00000a60| 64 65 20 72 65 63 74 61 | 6e 67 6c 65 2e 0d 09 09 |de recta|ngle....|
|00000a70| 09 09 0d 09 09 09 49 74 | 20 69 73 20 6e 6f 74 20 |......It| is not |
|00000a80| 63 68 65 63 6b 65 64 20 | 74 68 61 74 20 69 6e 73 |checked |that ins|
|00000a90| 69 64 65 20 69 73 20 69 | 6e 64 65 65 64 20 77 68 |ide is i|ndeed wh|
|00000aa0| 6f 6c 65 6c 79 20 69 6e | 73 69 64 65 20 6f 66 0d |olely in|side of.|
|00000ab0| 09 09 09 6f 75 74 73 69 | 64 65 20 2a 2a 29 0d 09 |...outsi|de **)..|
|00000ac0| 09 09 0d 09 09 09 66 75 | 6e 63 74 69 6f 6e 20 63 |......fu|nction c|
|00000ad0| 65 6e 74 65 72 72 65 63 | 74 28 20 6f 75 74 72 2c |enterrec|t( outr,|
|00000ae0| 20 69 6e 72 3a 20 72 65 | 63 74 20 29 3a 20 70 6f | inr: re|ct ): po|
|00000af0| 69 6e 74 3b 0d 09 09 09 | 09 76 61 72 20 70 3a 20 |int;....|.var p: |
|00000b00| 70 6f 69 6e 74 3b 0d 09 | 09 09 62 65 67 69 6e 0d |point;..|..begin.|
|00000b10| 09 09 09 09 70 2e 76 20 | 3a 3d 20 6f 75 74 72 2e |....p.v |:= outr.|
|00000b20| 74 6f 70 20 20 2b 20 28 | 28 28 6f 75 74 72 2e 62 |top + (|((outr.b|
|00000b30| 6f 74 74 6f 6d 20 2d 20 | 6f 75 74 72 2e 74 6f 70 |ottom - |outr.top|
|00000b40| 29 20 2d 20 28 69 6e 72 | 2e 62 6f 74 74 6f 6d 20 |) - (inr|.bottom |
|00000b50| 20 2d 20 69 6e 72 2e 74 | 6f 70 29 29 20 64 69 76 | - inr.t|op)) div|
|00000b60| 20 32 29 3b 0d 09 09 09 | 09 70 2e 68 20 3a 3d 20 | 2);....|.p.h := |
|00000b70| 6f 75 74 72 2e 6c 65 66 | 74 20 2b 20 28 28 28 6f |outr.lef|t + (((o|
|00000b80| 75 74 72 2e 72 69 67 68 | 74 20 2d 20 6f 75 74 72 |utr.righ|t - outr|
|00000b90| 2e 6c 65 66 74 29 20 2d | 20 28 69 6e 72 2e 72 69 |.left) -| (inr.ri|
|00000ba0| 67 68 74 20 20 2d 20 69 | 6e 72 2e 6c 65 66 74 29 |ght - i|nr.left)|
|00000bb0| 29 20 64 69 76 20 32 29 | 3b 0d 09 09 09 09 63 65 |) div 2)|;.....ce|
|00000bc0| 6e 74 65 72 72 65 63 74 | 20 3a 3d 20 70 0d 09 09 |nterrect| := p...|
|00000bd0| 09 65 6e 64 28 2a 20 63 | 65 6e 74 65 72 20 72 65 |.end(* c|enter re|
|00000be0| 63 74 20 2a 29 3b 0d 0d | 09 09 09 0d 09 09 09 28 |ct *);..|.......(|
|00000bf0| 2a 2a 09 43 61 72 64 20 | 52 65 63 74 0d 09 09 09 |**.Card |Rect....|
|00000c00| 0d 09 09 09 54 68 69 73 | 20 66 75 6e 63 74 69 6f |....This| functio|
|00000c10| 6e 20 77 69 6c 6c 20 72 | 65 74 75 72 6e 20 61 20 |n will r|eturn a |
|00000c20| 72 65 63 74 61 6e 67 6c | 65 20 74 68 61 74 20 73 |rectangl|e that s|
|00000c30| 70 65 63 69 66 69 65 73 | 20 77 68 65 72 65 0d 09 |pecifies| where..|
|00000c40| 09 09 74 68 65 20 48 79 | 70 65 72 43 61 72 64 20 |..the Hy|perCard |
|00000c50| 77 69 6e 64 6f 77 20 28 | 61 6b 61 20 74 68 69 73 |window (|aka this|
|00000c60| 20 63 61 72 64 29 20 69 | 73 20 75 70 6f 6e 20 74 | card) i|s upon t|
|00000c70| 68 65 20 73 63 72 65 65 | 6e 2e 0d 09 09 09 49 74 |he scree|n.....It|
|00000c80| 20 73 68 6f 75 6c 64 20 | 62 65 20 6e 6f 74 65 64 | should |be noted|
|00000c90| 20 74 68 61 74 20 74 68 | 65 20 70 6f 73 69 74 69 | that th|e positi|
|00000ca0| 6f 6e 20 69 73 20 64 65 | 74 65 72 6d 69 6e 65 64 |on is de|termined|
|00000cb0| 20 62 79 20 61 73 6b 69 | 6e 67 0d 09 09 09 48 79 | by aski|ng....Hy|
|00000cc0| 70 65 72 43 61 72 64 20 | 72 61 74 68 65 72 20 74 |perCard |rather t|
|00000cd0| 68 61 6e 20 63 61 6c 6c | 69 6e 67 20 74 6f 6f 6c |han call|ing tool|
|00000ce0| 62 6f 78 20 72 6f 75 74 | 69 6e 65 73 2e 20 2a 2a |box rout|ines. **|
|00000cf0| 29 0d 09 09 09 0d 09 09 | 09 66 75 6e 63 74 69 6f |).......|.functio|
|00000d00| 6e 20 63 61 72 64 72 65 | 63 74 3a 20 72 65 63 74 |n cardre|ct: rect|
|00000d10| 3b 0d 09 09 09 09 76 61 | 72 20 63 61 72 64 3a 20 |;.....va|r card: |
|00000d20| 72 65 63 74 3b 0d 09 09 | 09 62 65 67 69 6e 0d 09 |rect;...|.begin..|
|00000d30| 09 09 09 63 61 72 64 2e | 74 6f 70 20 20 20 20 3a |...card.|top :|
|00000d40| 3d 20 50 61 72 61 6d 54 | 6f 4e 75 6d 28 20 65 76 |= ParamT|oNum( ev|
|00000d50| 61 6c 65 78 70 72 28 20 | 27 69 74 65 6d 20 74 77 |alexpr( |'item tw|
|00000d60| 6f 20 6f 66 20 6c 6f 63 | 20 6f 66 20 63 61 72 64 |o of loc| of card|
|00000d70| 20 77 69 6e 64 6f 77 27 | 20 29 20 29 3b 0d 09 09 | window'| ) );...|
|00000d80| 09 09 63 61 72 64 2e 6c | 65 66 74 20 20 20 3a 3d |..card.l|eft :=|
|00000d90| 20 50 61 72 61 6d 54 6f | 4e 75 6d 28 20 65 76 61 | ParamTo|Num( eva|
|00000da0| 6c 65 78 70 72 28 20 27 | 69 74 65 6d 20 6f 6e 65 |lexpr( '|item one|
|00000db0| 20 6f 66 20 6c 6f 63 20 | 6f 66 20 63 61 72 64 20 | of loc |of card |
|00000dc0| 77 69 6e 64 6f 77 27 20 | 29 20 29 3b 0d 09 09 09 |window' |) );....|
|00000dd0| 09 63 61 72 64 2e 62 6f | 74 74 6f 6d 20 3a 3d 20 |.card.bo|ttom := |
|00000de0| 63 61 72 64 2e 74 6f 70 | 20 20 2b 20 33 34 32 3b |card.top| + 342;|
|00000df0| 0d 09 09 09 09 63 61 72 | 64 2e 72 69 67 68 74 20 |.....car|d.right |
|00000e00| 20 3a 3d 20 63 61 72 64 | 2e 6c 65 66 74 20 2b 20 | := card|.left + |
|00000e10| 35 31 32 3b 0d 09 09 09 | 09 63 61 72 64 72 65 63 |512;....|.cardrec|
|00000e20| 74 09 3a 3d 20 63 61 72 | 64 0d 09 09 09 65 6e 64 |t.:= car|d....end|
|00000e30| 28 2a 20 63 61 72 64 20 | 72 65 63 74 20 2a 29 3b |(* card |rect *);|
|00000e40| 0d 09 09 09 0d 09 09 09 | 0d 09 09 09 28 2a 2a 09 |........|....(**.|
|00000e50| 44 69 61 6c 6f 67 20 52 | 65 63 74 0d 09 09 09 0d |Dialog R|ect.....|
|00000e60| 09 09 09 54 68 69 73 20 | 66 75 6e 63 74 69 6f 6e |...This |function|
|00000e70| 20 72 65 74 75 72 6e 73 | 20 61 20 72 65 63 74 61 | returns| a recta|
|00000e80| 6e 67 6c 65 20 74 68 61 | 74 20 73 70 65 63 69 66 |ngle tha|t specif|
|00000e90| 69 65 73 20 77 68 65 72 | 65 20 74 68 65 0d 09 09 |ies wher|e the...|
|00000ea0| 09 53 46 50 75 74 46 69 | 6c 65 20 64 69 61 6c 6f |.SFPutFi|le dialo|
|00000eb0| 67 20 77 68 6f 75 6c 64 | 20 62 65 20 70 6c 61 63 |g whould| be plac|
|00000ec0| 65 64 20 75 70 6f 6e 20 | 74 68 65 20 73 63 72 65 |ed upon |the scre|
|00000ed0| 65 6e 2e 20 2a 2a 29 0d | 09 09 09 0d 09 09 09 66 |en. **).|.......f|
|00000ee0| 75 6e 63 74 69 6f 6e 20 | 64 69 61 6c 6f 67 72 65 |unction |dialogre|
|00000ef0| 63 74 3a 20 72 65 63 74 | 3b 0d 09 09 09 09 76 61 |ct: rect|;.....va|
|00000f00| 72 20 64 69 61 6c 6f 67 | 3a 20 64 69 61 6c 6f 67 |r dialog|: dialog|
|00000f10| 74 68 6e 64 6c 3b 0d 09 | 09 09 62 65 67 69 6e 0d |thndl;..|..begin.|
|00000f20| 09 09 09 09 64 69 61 6c | 6f 67 09 20 20 20 3a 3d |....dial|og. :=|
|00000f30| 20 64 69 61 6c 6f 67 74 | 68 6e 64 6c 28 20 67 65 | dialogt|hndl( ge|
|00000f40| 74 72 65 73 6f 75 72 63 | 65 28 20 27 44 4c 4f 47 |tresourc|e( 'DLOG|
|00000f50| 27 2c 20 70 75 74 64 6c | 67 69 64 20 29 20 29 3b |', putdl|gid ) );|
|00000f60| 0d 09 09 09 09 64 69 61 | 6c 6f 67 72 65 63 74 20 |.....dia|logrect |
|00000f70| 3a 3d 20 64 69 61 6c 6f | 67 5e 5e 2e 62 6f 75 6e |:= dialo|g^^.boun|
|00000f80| 64 73 72 65 63 74 0d 09 | 09 09 65 6e 64 28 2a 20 |dsrect..|..end(* |
|00000f90| 64 69 61 6c 6f 67 20 72 | 65 63 74 20 2a 29 3b 0d |dialog r|ect *);.|
|00000fa0| 09 09 09 0d 09 09 09 0d | 09 09 09 28 2a 2a 09 42 |........|...(**.B|
|00000fb0| 75 69 6c 64 20 50 61 74 | 68 6e 61 6d 65 0d 09 09 |uild Pat|hname...|
|00000fc0| 09 0d 09 09 09 54 68 69 | 73 20 66 75 6e 63 74 69 |.....Thi|s functi|
|00000fd0| 6f 6e 20 77 69 6c 6c 20 | 72 65 74 75 72 6e 20 74 |on will |return t|
|00000fe0| 68 65 20 66 75 6c 6c 20 | 70 61 74 68 6e 61 6d 65 |he full |pathname|
|00000ff0| 20 66 72 6f 6d 20 74 68 | 65 20 76 6f 6c 75 6d 65 | from th|e volume|
|00001000| 0d 09 09 09 72 65 66 65 | 72 65 6e 63 65 20 6e 75 |....refe|rence nu|
|00001010| 6d 62 65 72 20 61 6e 64 | 20 66 69 6c 65 6e 61 6d |mber and| filenam|
|00001020| 65 2e 20 20 54 68 69 73 | 20 63 6f 64 65 20 69 73 |e. This| code is|
|00001030| 20 61 20 74 61 6b 65 6e | 20 66 72 6f 6d 0d 09 09 | a taken| from...|
|00001040| 09 53 74 65 76 65 20 4d | 61 6c 6c 65 72 27 73 20 |.Steve M|aller's |
|00001050| 6f 72 69 67 69 6e 61 6c | 20 58 46 75 6e 63 74 69 |original| XFuncti|
|00001060| 6f 6e 20 22 46 69 6c 65 | 4e 61 6d 65 22 2e 20 2a |on "File|Name". *|
|00001070| 2a 29 0d 09 09 09 0d 09 | 09 09 66 75 6e 63 74 69 |*)......|..functi|
|00001080| 6f 6e 20 62 75 69 6c 64 | 70 61 74 68 6e 61 6d 65 |on build|pathname|
|00001090| 28 20 76 6f 6c 75 6d 65 | 3a 69 6e 74 65 67 65 72 |( volume|:integer|
|000010a0| 3b 20 66 69 6c 65 6e 61 | 6d 65 3a 20 73 74 72 32 |; filena|me: str2|
|000010b0| 35 35 29 3a 20 53 74 72 | 32 35 35 3b 0d 09 09 09 |55): Str|255;....|
|000010c0| 09 76 61 72 20 66 75 6c | 6c 70 61 74 68 6e 61 6d |.var ful|lpathnam|
|000010d0| 65 3a 20 73 74 72 32 35 | 35 3b 0d 09 09 09 09 09 |e: str25|5;......|
|000010e0| 6e 61 6d 65 09 09 3a 20 | 73 74 72 32 35 35 3b 0d |name..: |str255;.|
|000010f0| 09 09 09 09 09 65 72 72 | 09 09 09 3a 20 69 6e 74 |.....err|...: int|
|00001100| 65 67 65 72 3b 0d 09 09 | 09 09 09 6d 79 77 64 70 |eger;...|...mywdp|
|00001110| 62 09 09 3a 20 77 64 70 | 62 70 74 72 3b 0d 09 09 |b..: wdp|bptr;...|
|00001120| 09 09 09 6d 79 63 70 62 | 09 09 3a 20 63 69 6e 66 |...mycpb|..: cinf|
|00001130| 6f 70 62 70 74 72 3b 0d | 09 09 09 09 09 6d 79 70 |opbptr;.|.....myp|
|00001140| 62 09 09 3a 20 68 70 61 | 72 6d 62 6c 6b 70 74 72 |b..: hpa|rmblkptr|
|00001150| 3b 0d 09 09 09 62 65 67 | 69 6e 0d 09 09 09 0d 09 |;....beg|in......|
|00001160| 09 09 09 62 75 69 6c 64 | 70 61 74 68 6e 61 6d 65 |...build|pathname|
|00001170| 20 3a 3d 20 27 27 3b 0d | 09 09 09 09 0d 09 09 09 | := '';.|........|
|00001180| 09 7b 20 0d 09 09 09 09 | 66 69 72 73 74 20 77 65 |.{ .....|first we|
|00001190| 20 61 6c 6c 6f 63 61 74 | 65 20 73 6f 6d 65 20 6d | allocat|e some m|
|000011a0| 65 6d 6f 72 79 20 69 6e | 20 74 68 65 20 68 65 61 |emory in| the hea|
|000011b0| 70 20 66 6f 72 20 74 68 | 65 20 0d 09 09 09 09 70 |p for th|e .....p|
|000011c0| 61 72 61 6d 65 74 65 72 | 20 62 6c 6f 63 6b 2e 20 |arameter| block. |
|000011d0| 74 68 69 73 20 63 6f 75 | 6c 64 20 69 6e 20 74 68 |this cou|ld in th|
|000011e0| 65 6f 72 79 20 77 6f 72 | 6b 20 6f 6e 20 74 68 65 |eory wor|k on the|
|000011f0| 20 73 74 61 63 6b 2c 20 | 0d 09 09 09 09 62 75 74 | stack, |.....but|
|00001200| 20 69 6e 20 72 65 61 6c | 69 74 79 20 69 74 20 6d | in real|ity it m|
|00001210| 61 6b 65 73 20 6e 6f 20 | 64 69 66 66 65 72 65 6e |akes no |differen|
|00001220| 63 65 20 61 73 20 77 65 | 27 72 65 20 65 6e 74 69 |ce as we|'re enti|
|00001230| 72 65 6c 79 20 0d 09 09 | 09 09 6d 6f 64 61 6c 20 |rely ...|..modal |
|00001240| 28 75 67 68 29 20 68 65 | 72 65 2e 2e 2e 0d 09 09 |(ugh) he|re......|
|00001250| 09 09 7d 0d 09 09 09 09 | 6d 79 63 70 62 20 20 3a |..}.....|mycpb :|
|00001260| 3d 20 63 69 6e 66 6f 70 | 62 70 74 72 28 6e 65 77 |= cinfop|bptr(new|
|00001270| 70 74 72 28 73 69 7a 65 | 6f 66 28 68 70 61 72 61 |ptr(size|of(hpara|
|00001280| 6d 62 6c 6f 63 6b 72 65 | 63 29 29 29 3b 0d 09 09 |mblockre|c)));...|
|00001290| 09 09 69 66 20 6f 72 64 | 34 28 6d 79 63 70 62 29 |..if ord|4(mycpb)|
|000012a0| 20 3c 3d 20 30 20 74 68 | 65 6e 0d 09 09 09 09 09 | <= 0 th|en......|
|000012b0| 65 78 69 74 28 62 75 69 | 6c 64 70 61 74 68 6e 61 |exit(bui|ldpathna|
|000012c0| 6d 65 29 3b 09 09 09 7b | 20 72 61 74 73 21 20 62 |me);...{| rats! b|
|000012d0| 69 6c 6c 20 64 69 64 6e | 27 74 20 6c 65 61 76 65 |ill didn|'t leave|
|000012e0| 20 65 6e 6f 75 67 68 20 | 72 6f 6f 6d 20 7d 0d 09 | enough |room }..|
|000012f0| 09 09 09 6d 79 77 64 70 | 62 20 3a 3d 20 77 64 70 |...mywdp|b := wdp|
|00001300| 62 70 74 72 28 6d 79 63 | 70 62 29 3b 09 09 09 7b |bptr(myc|pb);...{|
|00001310| 20 69 63 6b 79 20 70 61 | 73 63 61 6c 20 74 79 70 | icky pa|scal typ|
|00001320| 65 20 63 6f 65 72 63 69 | 6f 6e 73 20 66 6f 6c 6c |e coerci|ons foll|
|00001330| 6f 77 20 7d 0d 09 09 09 | 09 6d 79 70 62 20 20 20 |ow }....|.mypb |
|00001340| 3a 3d 20 68 70 61 72 6d | 62 6c 6b 70 74 72 28 6d |:= hparm|blkptr(m|
|00001350| 79 63 70 62 29 3b 0d 0d | 0d 09 09 09 09 6e 61 6d |ycpb);..|.....nam|
|00001360| 65 20 3a 3d 20 27 27 3b | 20 20 20 20 20 20 20 20 |e := '';| |
|00001370| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00001380| 20 7b 20 73 74 61 72 74 | 20 77 69 74 68 20 61 6e | { start| with an|
|00001390| 20 65 6d 70 74 79 20 6e | 61 6d 65 20 7d 0d 09 09 | empty n|ame }...|
|000013a0| 09 09 6d 79 70 62 5e 2e | 69 6f 6e 61 6d 65 70 74 |..mypb^.|ionamept|
|000013b0| 72 20 3a 3d 20 40 6e 61 | 6d 65 3b 09 09 09 7b 20 |r := @na|me;...{ |
|000013c0| 77 65 20 77 61 6e 74 20 | 74 68 65 20 76 6f 6c 75 |we want |the volu|
|000013d0| 6d 65 20 6e 61 6d 65 20 | 7d 0d 09 09 09 09 6d 79 |me name |}.....my|
|000013e0| 70 62 5e 2e 69 6f 63 6f | 6d 70 6c 65 74 69 6f 6e |pb^.ioco|mpletion|
|000013f0| 20 3a 3d 20 70 6f 69 6e | 74 65 72 28 30 29 3b 0d | := poin|ter(0);.|
|00001400| 09 09 09 09 6d 79 70 62 | 5e 2e 69 6f 76 72 65 66 |....mypb|^.iovref|
|00001410| 6e 75 6d 20 3a 3d 20 76 | 6f 6c 75 6d 65 3b 09 09 |num := v|olume;..|
|00001420| 09 7b 20 72 65 74 75 72 | 6e 65 64 20 66 72 6f 6d |.{ retur|ned from|
|00001430| 20 73 66 67 65 74 66 69 | 6c 65 20 7d 0d 09 09 09 | sfgetfi|le }....|
|00001440| 09 6d 79 70 62 5e 2e 69 | 6f 76 6f 6c 69 6e 64 65 |.mypb^.i|ovolinde|
|00001450| 78 20 3a 3d 20 30 3b 09 | 09 09 09 7b 20 75 73 65 |x := 0;.|...{ use|
|00001460| 20 74 68 65 20 76 72 65 | 66 6e 75 6d 20 61 6e 64 | the vre|fnum and|
|00001470| 20 6e 61 6d 65 20 7d 0d | 09 09 09 09 65 72 72 20 | name }.|....err |
|00001480| 3a 3d 20 70 62 68 67 65 | 74 76 69 6e 66 6f 28 6d |:= pbhge|tvinfo(m|
|00001490| 79 70 62 2c 20 66 61 6c | 73 65 29 3b 09 7b 20 66 |ypb, fal|se);.{ f|
|000014a0| 69 6c 6c 20 69 6e 20 74 | 68 65 20 76 6f 6c 75 6d |ill in t|he volum|
|000014b0| 65 20 69 6e 66 6f 20 7d | 0d 09 09 09 09 69 66 20 |e info }|.....if |
|000014c0| 65 72 72 20 3c 3e 20 6e | 6f 65 72 72 20 74 68 65 |err <> n|oerr the|
|000014d0| 6e 0d 09 09 09 09 09 65 | 78 69 74 28 62 75 69 6c |n......e|xit(buil|
|000014e0| 64 70 61 74 68 6e 61 6d | 65 29 3b 0d 0d 09 09 09 |dpathnam|e);.....|
|000014f0| 09 7b 20 09 0d 09 09 09 | 09 6e 6f 77 20 77 65 20 |.{ .....|.now we |
|00001500| 6e 65 65 64 20 74 68 65 | 20 77 6f 72 6b 69 6e 67 |need the| working|
|00001510| 20 64 69 72 65 63 74 6f | 72 79 20 28 77 64 29 20 | directo|ry (wd) |
|00001520| 69 6e 66 6f 72 6d 61 74 | 69 6f 6e 20 0d 09 09 09 |informat|ion ....|
|00001530| 09 62 65 63 61 75 73 65 | 20 77 65 27 72 65 20 67 |.because| we're g|
|00001540| 6f 69 6e 67 20 74 6f 20 | 73 74 65 70 20 62 61 63 |oing to |step bac|
|00001550| 6b 77 61 72 64 73 20 66 | 72 6f 6d 20 74 68 65 20 |kwards f|rom the |
|00001560| 66 69 6c 65 20 0d 09 09 | 09 09 74 68 72 6f 75 67 |file ...|..throug|
|00001570| 68 20 61 6c 6c 20 6f 66 | 20 74 68 65 20 74 68 65 |h all of| the the|
|00001580| 20 66 6f 6c 64 65 72 73 | 20 75 6e 74 69 6c 20 77 | folders| until w|
|00001590| 65 20 72 65 61 63 68 20 | 74 68 65 20 0d 09 09 09 |e reach |the ....|
|000015a0| 09 72 6f 6f 74 20 64 69 | 72 65 63 74 6f 72 79 0d |.root di|rectory.|
|000015b0| 09 09 09 09 7d 0d 09 09 | 09 09 6d 79 77 64 70 62 |....}...|..mywdpb|
|000015c0| 5e 2e 69 6f 76 72 65 66 | 6e 75 6d 20 3a 3d 20 76 |^.iovref|num := v|
|000015d0| 6f 6c 75 6d 65 3b 09 09 | 7b 20 74 68 69 73 20 67 |olume;..|{ this g|
|000015e0| 6f 74 20 73 65 74 20 74 | 6f 20 30 20 61 62 6f 76 |ot set t|o 0 abov|
|000015f0| 65 20 7d 09 09 09 09 09 | 6d 79 77 64 70 62 5e 2e |e }.....|mywdpb^.|
|00001600| 69 6f 77 64 70 72 6f 63 | 69 64 20 3a 3d 20 30 3b |iowdproc|id := 0;|
|00001610| 09 09 09 09 09 09 09 7b | 20 75 73 65 20 74 68 65 |.......{| use the|
|00001620| 20 76 72 65 66 6e 75 6d | 20 7d 0d 09 09 09 09 6d | vrefnum| }.....m|
|00001630| 79 77 64 70 62 5e 2e 69 | 6f 77 64 69 6e 64 65 78 |ywdpb^.i|owdindex|
|00001640| 20 3a 3d 20 30 3b 09 09 | 09 09 7b 20 77 65 20 77 | := 0;..|..{ we w|
|00001650| 61 6e 74 20 61 6c 6c 20 | 64 69 72 65 63 74 6f 72 |ant all |director|
|00001660| 69 65 73 20 7d 0d 09 09 | 09 09 65 72 72 20 3a 3d |ies }...|..err :=|
|00001670| 20 70 62 67 65 74 77 64 | 69 6e 66 6f 28 6d 79 77 | pbgetwd|info(myw|
|00001680| 64 70 62 2c 20 66 61 6c | 73 65 29 3b 09 7b 20 64 |dpb, fal|se);.{ d|
|00001690| 6f 20 69 74 20 7d 0d 09 | 09 09 09 69 66 20 65 72 |o it }..|...if er|
|000016a0| 72 20 3c 3e 20 6e 6f 65 | 72 72 20 74 68 65 6e 0d |r <> noe|rr then.|
|000016b0| 09 09 09 09 09 65 78 69 | 74 28 62 75 69 6c 64 70 |.....exi|t(buildp|
|000016c0| 61 74 68 6e 61 6d 65 29 | 3b 0d 0d 09 09 09 09 6d |athname)|;......m|
|000016d0| 79 63 70 62 5e 2e 69 6f | 66 64 69 72 69 6e 64 65 |ycpb^.io|fdirinde|
|000016e0| 78 20 3a 3d 20 2d 20 31 | 3b 09 09 09 09 7b 20 75 |x := - 1|;....{ u|
|000016f0| 73 65 20 74 68 65 20 69 | 6f 64 69 72 69 64 20 66 |se the i|odirid f|
|00001700| 69 65 6c 64 20 6f 6e 6c | 79 20 7d 0d 09 09 09 09 |ield onl|y }.....|
|00001710| 6d 79 63 70 62 5e 2e 69 | 6f 64 72 64 69 72 69 64 |mycpb^.i|odrdirid|
|00001720| 20 3a 3d 20 6d 79 77 64 | 70 62 5e 2e 69 6f 77 64 | := mywd|pb^.iowd|
|00001730| 64 69 72 69 64 3b 09 7b | 20 69 6e 66 6f 20 72 65 |dirid;.{| info re|
|00001740| 74 75 72 6e 65 64 20 61 | 62 6f 76 65 20 7d 0d 09 |turned a|bove }..|
|00001750| 09 09 09 65 72 72 20 3a | 3d 20 70 62 67 65 74 63 |...err :|= pbgetc|
|00001760| 61 74 69 6e 66 6f 28 6d | 79 63 70 62 2c 20 66 61 |atinfo(m|ycpb, fa|
|00001770| 6c 73 65 29 3b 09 09 7b | 20 64 6f 20 69 74 20 7d |lse);..{| do it }|
|00001780| 0d 09 09 09 09 69 66 20 | 65 72 72 20 3c 3e 20 6e |.....if |err <> n|
|00001790| 6f 65 72 72 20 74 68 65 | 6e 0d 09 09 09 09 09 65 |oerr the|n......e|
|000017a0| 78 69 74 28 62 75 69 6c | 64 70 61 74 68 6e 61 6d |xit(buil|dpathnam|
|000017b0| 65 29 3b 0d 0d 09 09 09 | 09 7b 0d 09 09 09 09 68 |e);.....|.{.....h|
|000017c0| 65 72 65 20 73 74 61 72 | 74 73 20 74 68 65 20 72 |ere star|ts the r|
|000017d0| 65 61 6c 20 77 6f 72 6b | 20 2d 20 73 74 61 72 74 |eal work| - start|
|000017e0| 20 74 6f 20 63 6c 69 6d | 62 20 74 68 65 20 74 72 | to clim|b the tr|
|000017f0| 65 65 20 62 79 20 0d 09 | 09 09 09 63 6f 6e 74 69 |ee by ..|...conti|
|00001800| 6e 75 61 6c 6c 79 09 6c | 6f 6f 6b 69 6e 67 20 69 |nually.l|ooking i|
|00001810| 6e 20 74 68 65 20 69 6f | 64 72 70 61 72 69 64 20 |n the io|drparid |
|00001820| 66 69 65 6c 64 20 66 6f | 72 20 74 68 65 20 6e 65 |field fo|r the ne|
|00001830| 78 74 20 0d 09 09 09 09 | 64 69 72 65 63 74 6f 72 |xt .....|director|
|00001840| 79 20 61 62 6f 76 65 20 | 75 6e 74 69 6c 20 77 65 |y above |until we|
|00001850| 20 66 61 69 6c 2e 2e 2e | 20 0d 09 09 09 09 7d 0d | fail...| .....}.|
|00001860| 09 09 09 09 6d 79 63 70 | 62 5e 2e 69 6f 64 72 64 |....mycp|b^.iodrd|
|00001870| 69 72 69 64 20 3a 3d 20 | 6d 79 63 70 62 5e 2e 69 |irid := |mycpb^.i|
|00001880| 6f 64 72 70 61 72 69 64 | 3b 09 7b 20 74 68 65 20 |odrparid|;.{ the |
|00001890| 66 69 72 73 74 20 66 6f | 6c 64 65 72 7d 0d 09 09 |first fo|lder}...|
|000018a0| 09 09 66 75 6c 6c 70 61 | 74 68 6e 61 6d 65 20 09 |..fullpa|thname .|
|000018b0| 20 3a 3d 20 63 6f 6e 63 | 61 74 28 6d 79 63 70 62 | := conc|at(mycpb|
|000018c0| 5e 2e 69 6f 6e 61 6d 65 | 70 74 72 5e 2c 20 27 3a |^.ioname|ptr^, ':|
|000018d0| 27 2c 20 66 69 6c 65 6e | 61 6d 65 29 3b 0d 09 09 |', filen|ame);...|
|000018e0| 09 09 0d 09 09 09 09 72 | 65 70 65 61 74 0d 09 09 |.......r|epeat...|
|000018f0| 09 09 09 6d 79 63 70 62 | 5e 2e 69 6f 64 72 64 69 |...mycpb|^.iodrdi|
|00001900| 72 69 64 20 3a 3d 20 6d | 79 63 70 62 5e 2e 69 6f |rid := m|ycpb^.io|
|00001910| 64 72 70 61 72 69 64 3b | 0d 09 09 09 09 09 65 72 |drparid;|......er|
|00001920| 72 20 3a 3d 20 70 62 67 | 65 74 63 61 74 69 6e 66 |r := pbg|etcatinf|
|00001930| 6f 28 6d 79 63 70 62 2c | 20 66 61 6c 73 65 29 3b |o(mycpb,| false);|
|00001940| 09 7b 20 74 68 65 20 6e | 65 78 74 20 6c 65 76 65 |.{ the n|ext leve|
|00001950| 6c 20 7d 0d 0d 09 09 09 | 09 09 7b 20 0d 09 09 09 |l }.....|..{ ....|
|00001960| 09 09 62 65 20 63 61 72 | 65 66 75 6c 20 6f 66 20 |..be car|eful of |
|00001970| 61 6e 20 65 72 72 6f 72 | 20 72 65 74 75 72 6e 65 |an error| returne|
|00001980| 64 20 68 65 72 65 20 2d | 20 69 74 20 6d 65 61 6e |d here -| it mean|
|00001990| 73 20 74 68 65 20 75 73 | 65 72 20 0d 09 09 09 09 |s the us|er .....|
|000019a0| 09 63 68 6f 73 65 20 61 | 20 66 69 6c 65 20 6f 6e |.chose a| file on|
|000019b0| 20 74 68 65 20 64 65 73 | 6b 74 6f 70 20 6c 65 76 | the des|ktop lev|
|000019c0| 65 6c 20 6f 66 20 74 68 | 69 73 20 76 6f 6c 75 6d |el of th|is volum|
|000019d0| 65 2e 20 69 66 20 74 68 | 69 73 20 0d 09 09 09 09 |e. if th|is .....|
|000019e0| 09 69 73 20 74 68 65 20 | 63 61 73 65 2c 20 6a 75 |.is the |case, ju|
|000019f0| 73 74 20 73 74 6f 70 20 | 68 65 72 65 20 61 6e 64 |st stop |here and|
|00001a00| 20 72 65 74 75 72 6e 20 | 22 76 6f 6c 75 6d 65 6e | return |"volumen|
|00001a10| 61 6d 65 3a 66 69 6c 65 | 6e 61 6d 65 22 2c 20 0d |ame:file|name", .|
|00001a20| 09 09 09 09 09 6f 74 68 | 65 72 77 69 73 65 20 6c |.....oth|erwise l|
|00001a30| 6f 6f 70 20 75 6e 74 69 | 6c 20 66 61 69 6c 75 72 |oop unti|l failur|
|00001a40| 65 20 0d 09 09 09 09 09 | 7d 0d 09 09 09 09 09 0d |e ......|}.......|
|00001a50| 09 09 09 09 09 69 66 20 | 65 72 72 20 3d 20 6e 6f |.....if |err = no|
|00001a60| 65 72 72 20 74 68 65 6e | 0d 09 09 09 09 09 09 66 |err then|.......f|
|00001a70| 75 6c 6c 70 61 74 68 6e | 61 6d 65 20 3a 3d 20 63 |ullpathn|ame := c|
|00001a80| 6f 6e 63 61 74 28 6d 79 | 63 70 62 5e 2e 69 6f 6e |oncat(my|cpb^.ion|
|00001a90| 61 6d 65 70 74 72 5e 2c | 20 27 3a 27 2c 20 66 75 |ameptr^,| ':', fu|
|00001aa0| 6c 6c 70 61 74 68 6e 61 | 6d 65 29 3b 0d 0d 09 09 |llpathna|me);....|
|00001ab0| 09 09 75 6e 74 69 6c 20 | 65 72 72 20 3c 3e 20 6e |..until |err <> n|
|00001ac0| 6f 65 72 72 3b 0d 09 09 | 09 09 0d 09 09 09 09 64 |oerr;...|.......d|
|00001ad0| 69 73 70 6f 73 70 74 72 | 28 70 6f 69 6e 74 65 72 |isposptr|(pointer|
|00001ae0| 28 6d 79 63 70 62 29 29 | 3b 09 7b 20 63 6c 65 61 |(mycpb))|;.{ clea|
|00001af0| 6e 20 75 70 20 79 6f 75 | 72 20 68 65 61 70 21 20 |n up you|r heap! |
|00001b00| 7d 0d 0d 09 09 09 09 62 | 75 69 6c 64 70 61 74 68 |}......b|uildpath|
|00001b10| 6e 61 6d 65 20 3a 3d 20 | 66 75 6c 6c 70 61 74 68 |name := |fullpath|
|00001b20| 6e 61 6d 65 0d 09 09 09 | 09 0d 09 09 09 65 6e 64 |name....|.....end|
|00001b30| 28 2a 20 62 75 69 6c 64 | 20 70 61 74 68 20 6e 61 |(* build| path na|
|00001b40| 6d 65 20 2a 29 3b 0d 09 | 09 09 0d 09 09 62 65 67 |me *);..|.....beg|
|00001b50| 69 6e 0d 09 09 0d 09 09 | 09 77 69 74 68 20 70 61 |in......|.with pa|
|00001b60| 72 61 6d 70 74 72 5e 20 | 64 6f 0d 09 09 09 09 62 |ramptr^ |do.....b|
|00001b70| 65 67 69 6e 09 0d 09 09 | 09 09 09 69 66 20 70 61 |egin....|...if pa|
|00001b80| 72 61 6d 63 6f 75 6e 74 | 20 3d 20 32 20 74 68 65 |ramcount| = 2 the|
|00001b90| 6e 0d 09 09 09 09 09 09 | 62 65 67 69 6e 0d 09 09 |n.......|begin...|
|00001ba0| 09 09 09 09 09 7a 65 72 | 6f 74 6f 70 61 73 28 20 |.....zer|otopas( |
|00001bb0| 70 61 72 61 6d 73 5b 20 | 31 20 5d 5e 2c 20 70 72 |params[ |1 ]^, pr|
|00001bc0| 6f 6d 70 74 20 29 3b 0d | 09 09 09 09 09 09 09 7a |ompt );.|.......z|
|00001bd0| 65 72 6f 74 6f 70 61 73 | 28 20 70 61 72 61 6d 73 |erotopas|( params|
|00001be0| 5b 20 32 20 5d 5e 2c 20 | 66 69 6c 65 6e 61 6d 65 |[ 2 ]^, |filename|
|00001bf0| 20 29 3b 0d 09 09 09 09 | 09 09 09 0d 09 09 09 09 | );.....|........|
|00001c00| 09 09 09 73 66 70 75 74 | 66 69 6c 65 28 20 63 65 |...sfput|file( ce|
|00001c10| 6e 74 65 72 72 65 63 74 | 28 20 63 61 72 64 72 65 |nterrect|( cardre|
|00001c20| 63 74 2c 20 64 69 61 6c | 6f 67 72 65 63 74 20 29 |ct, dial|ogrect )|
|00001c30| 2c 20 0d 09 09 09 09 09 | 09 09 09 09 20 20 20 70 |, ......|.... p|
|00001c40| 72 6f 6d 70 74 2c 20 66 | 69 6c 65 6e 61 6d 65 2c |rompt, f|ilename,|
|00001c50| 20 6e 69 6c 2c 20 72 65 | 70 6c 79 20 29 3b 0d 0d | nil, re|ply );..|
|00001c60| 09 09 09 09 09 09 09 69 | 66 20 72 65 70 6c 79 2e |.......i|f reply.|
|00001c70| 67 6f 6f 64 20 74 68 65 | 6e 0d 09 09 09 09 09 09 |good the|n.......|
|00001c80| 09 09 66 75 6c 6c 70 61 | 74 68 6e 61 6d 65 20 3a |..fullpa|thname :|
|00001c90| 3d 20 62 75 69 6c 64 70 | 61 74 68 6e 61 6d 65 28 |= buildp|athname(|
|00001ca0| 20 72 65 70 6c 79 2e 76 | 72 65 66 6e 75 6d 2c 20 | reply.v|refnum, |
|00001cb0| 0d 09 09 09 09 09 09 09 | 09 09 09 09 09 09 09 09 |........|........|
|00001cc0| 20 20 20 72 65 70 6c 79 | 2e 66 6e 61 6d 65 20 29 | reply|.fname )|
|00001cd0| 3b 0d 09 09 09 09 09 09 | 65 6e 64 3b 0d 09 09 09 |;.......|end;....|
|00001ce0| 09 09 09 0d 09 09 09 09 | 09 72 65 74 75 72 6e 76 |........|.returnv|
|00001cf0| 61 6c 75 65 20 3a 3d 20 | 70 61 73 74 6f 7a 65 72 |alue := |pastozer|
|00001d00| 6f 28 66 75 6c 6c 70 61 | 74 68 6e 61 6d 65 29 0d |o(fullpa|thname).|
|00001d10| 09 09 09 09 65 6e 64 0d | 0d 09 09 65 6e 64 28 2a |....end.|...end(*|
|00001d20| 20 6e 65 77 66 69 6c 65 | 6e 61 6d 65 20 2a 29 3b | newfile|name *);|
|00001d30| 0d 0d 65 6e 64 2e 00 00 | 00 00 00 00 00 00 00 00 |..end...|........|
|00001d40| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001d50| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001d60| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001d70| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00001d80| 00 00 01 00 00 00 01 4c | 00 00 00 4c 00 00 00 32 |.......L|...L...2|
|00001d90| 36 2e 00 0e 22 54 7e 00 | 3e 31 30 06 2a 2b 00 0c |6..."T~.|>10.*+..|
|00001da0| 47 f1 30 0a 20 6e 00 08 | 4a 6e 00 0c 67 06 76 00 |G.0. n..|Jn..g.v.|
|00001db0| 0d 4e 65 77 46 69 6c 65 | 4e 61 6d 65 2e 70 02 00 |.NewFile|Name.p..|
|00001dc0| 00 00 54 45 58 54 4d 50 | 53 20 01 00 00 00 00 00 |..TEXTMP|S ......|
|00001dd0| 00 00 54 45 58 54 4d 50 | 53 20 01 00 00 00 00 00 |..TEXTMP|S ......|
|00001de0| 00 00 55 0e 00 00 00 00 | 00 00 00 00 00 00 00 00 |..U.....|........|
|00001df0| 06 62 9d 9c 10 e2 00 00 | 1c 93 00 00 01 7e 60 00 |.b......|.....~`.|
|00001e00| ff 20 00 00 00 00 00 00 | 0f c0 08 60 08 70 08 10 |. ......|...`.p..|
|00001e10| 08 10 08 10 08 10 08 10 | 08 10 0f f0 00 00 00 00 |........|........|
|00001e20| 00 00 00 00 00 00 00 00 | 1e 00 21 f8 20 04 20 04 |........|..!. . .|
|00001e30| 20 04 20 04 20 04 20 04 | 3f fc 00 00 00 00 00 00 | . . . .|?.......|
|00001e40| 00 00 00 00 00 00 3f f0 | 48 a8 48 a4 48 24 47 c4 |......?.|H.H.H$G.|
|00001e50| 40 04 40 04 47 c4 48 24 | 48 24 48 24 3f fc 00 00 |@.@.G.H$|H$H$?...|
|00001e60| 00 00 00 00 00 00 00 00 | 1e 00 21 fc 20 02 ff e2 |........|..!. ...|
|00001e70| 80 12 40 12 40 0a 20 0a | 20 06 1f fe 00 00 00 00 |..@.@. .| .......|
|00001e80| 00 00 00 48 00 09 4d 6f | 6e 61 63 6f 00 00 00 00 |...H..Mo|naco....|
|00001e90| 00 00 00 00 00 24 00 00 | 00 16 00 01 03 ee 00 01 |.....$..|........|
|00001ea0| 00 00 04 2a 00 00 00 06 | 00 04 00 29 00 03 01 53 |...*....|...)...S|
|00001eb0| 01 fd 00 c9 00 08 01 4e | 01 f8 9d af 96 95 00 00 |.......N|........|
|00001ec0| 02 97 00 00 02 97 00 00 | 00 00 01 00 00 00 01 00 |........|........|
|00001ed0| 00 00 01 4c 00 00 00 4c | 00 00 00 32 00 02 15 20 |...L...L|...2... |
|00001ee0| 02 94 00 00 00 1c 00 32 | 00 00 4d 50 53 52 00 00 |.......2|..MPSR..|
|00001ef0| 00 0a 03 ed ff ff 00 00 | 00 00 00 03 18 06 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+