-not a Macintosh disk-3@F$h @ 3` #@@%rj NF,  8!"@$|Gn"`I N.@A,H<( F<B<H111Bx<kNNF`, 8! "NH@"|J(g g`LNu"_ |a||a0@||9݁g|w|a||NH瀀 |(_@"g2<@gBA?N`Fa`||aPLNu  fBR$N"NBH@&|݁ |B$<0HN~NL@dBgg>N&|)`RNuBBBA*2h/ BBB N _"_$_"H&|݁ |B$<0NNd 0<`L$|J HA H  2I<FFI<<FFfHHFFfHHH?B@L"_2N _0H 2<@I6@o Az:<2`6@oJA~:<26" @n2BDBB(`EB@nAJEkz`z2<HAIL0.NL0.N  / p? O@ 0  0  XO _,_2_!.NBBB/ BBBN08 @ gNu@ f"_E!NH\O/ ?`@&x|N _!@"|xEx En"`CE"|xN"Ҹ< A  33"|@E E4n"`C&E"|@.N _LHNFLN*8&E@CJJKK f`  f `><$CS*<F|4>BRIBC Gff&<CBSC`D GnKG45BQf` f `Ns |0< BXHQ!4 _$_"_!XOHH/8/ $ f0<? QN ! N.x $_$ g ! N.x !C !!LLyp!N\OFN  l0P߀ Aǀ`  6lo6@ 0_an*>]> j 56, l602  ۰Poo A` &ll6p@ 0?۷a?^ ꭕ 5o6, l602 8!ED91kE"0369? CoNGNOS BOOT FAILED TRY A NEWER MACHINE AND BOOT PROM _"_NN o0<BAN o0 _PON _"_$|0<J"PJQN _"_$|0<"PJQNHL$ orD?|?@?e\SFk!!QSWk:CL<HL|hH>L|4H>L|H>SWjTO>SGk\!Q`TSFk QSWk8L|H|L|H|4L|H|hL|H|LSGkQLx _O NNVH8=| f=|G* G, &N(N n"n$n 0.  S@ZeJ S@BBDBG S@gg.BC CJDg720faL`fa:` 320f8<S@`JDg  fa$` fa`  U@o$SBjt`(N&N><`JGg (Ev#$#$QNukJDg`g 3$f(N`BnLN^ _NUNPACK NV;n N^.NuEVINIT NVH,. ^J]g n0`4B?N. f n0`/.//. /.N(n)FLN^ _NEAD_BLONV/ (n Jno./.?././ /.Nj nJPg`RSn`(_N^ _NEAD_SEQHNT"|E.|r |BBByBygRBf~NuLHPPNqNqpS_n.0<QLHPPNqNqpS_n|~By&JM*Np|azJGfb|a|,Mpa`JGfH|a<<AaJGf0Avtp BQvr BQH@02N\LhL"4NtB@6Kd a"JDf`02IP g a JDf`Nub SBg pxNuBDNu><Nu4< vB@bp2IPSCfSBfNuppB@(4<dBC(4< CBC(C"H4<BACSBf(CAg><NuJoNV?-Nh.H|)?NpN^ _TONRAP NV.HgVS@g`J.f& -XмS//<N(/<N+_X-mX . ѭX -Xo<Np`B . TJ.f/-T/<N/<N+_T-mT -Tl<N,N^ _PONGETSPACNV .мS//<N/<NJ-_ .=@ N^.NuINDSPARNVH.. Bg/N0Hހ m0.@I/./<N( 8//<N @n ?.Bg?<BgN(LN^ _ NETMMU NV0. S@g S@gS@g`=|`=|` =|`BnN^ _\ONONV_DEVNVH nCJp"S@n2BgHnNE g BgNN=_   nV@g8B. Bmh|` @BvRF Fo mXf=|;|@`Bm@`|BgN;_hBgN> Ggd G] G^g$ GdfBgN;_@BgN>`<ND`.BgN8JD] D^g<N$ @=BgN>`|`.H@ABpR. .oBg?./N;_"Bg?./Nz;_,Bg?./Nj;_.Bg?./NZ;_0-| nBPLN^.NuEAD_CONNVH nCJp"S@n~`LH6p@J@^H6pA A_gH6p@H"AA1`H @ABpR o;nh0.H@;@@A r<Ё(@&|H@6LN^.NuROCESS_NVLH nCJp"S@n2BgHnNAx/NAx/HndNJndV nxVgB-e`|e  gHnxNA&HA(AL,*<Hnf?-Z E0-NPH///NJnfg<N(A(H/ HndN.JndV TVg B-fmeg`l-eg*0.zlW"-BWD@f-f @g` B-g -Bf|f/ N`B-f  -e -fg/ NLN^.NuNIT_CONNVH+| \+|l+|(|+|t+|+|l+|(|;TN(|;TZ(|;TX&| n!SLN^.NuETVARS NVH/Nt;| ./+@ .м/м+@+|X*<(< E"D +@T&|?-Z0-NS?NHnHmBNJngp+@BAC6 0HnNBBg/-BgN+_ -Э+@PBB<0<H/BgNZN<+_H+mHBG` m @I G~V GTVgd Gl|p@ @8`$ Gf|p@BT`| p@BT H< @"@=A?.??<BgNJRG Gox mI|p@BT mIP|p@/-H/<N 8LN^NuOOTINIT system.configNVH(nB BgN@BgN8HH,BgNp0HѬ f,/, NBgNBgNHH,BgN>0HѬ f,/, NZBgNBgNHH,BgN 0HѬ f:J`f< N/, NBgNBgNHH,BgN0HѬ g<NHBN,BN+_ n/BN  _r Ё0p//-XN /-/-XN&mX:=E E0o<N0<H+@d+| -dЭ\ n2HҀ -Ё"-Ҁ(Bg Э/N0Hѭ -Є+@B</-BgN+_+m` -\Э`+@h -dЭh, n0HІ+@ -Э+@ -Э+@?<f/-/-?<N^-m/ /./-N n LN^ _ NUILD_SYNVH(nBGBF. gB `P-n n0. PoB."` n0. A-H&n/+/<N&  n0>+<+/, N$BgNBgNHH-@BgN0H(٬ JVJ_gB."`4JGW WJGV WgJFf n `H n n/B."n/BgN.  _ BN-_JGf n Q/ n P/N` Q@H/ n P/N|B. n=h-nA-H n-P/./.p/NJGgR-m`Bg n/( n r Ё/ n P/ nP/ | ? Q@?N9_Jlg< N( nQ f|"LN^ _NOADSEG NV/ BBg/-lBgN+_p -p"-Ҁ+Al(|`p}//<N -Пp((|p}//<N -Пp(?<}/-p/-l?<N(_N^.NuLLOC_SCNVHAC 0BgHnN __m_^+m-^gBBg/-BgNX+_`+m-_gBBg/<BgN4 м,BgBgBHnBgHnHnBg/.N g<NACD 0BgHnN p g B-n`.BgBgBHnBgHnHnBg/.N g<Nn .@+@n -Эn+@j` B -@+@n -м@+@j?</-n/-j?<NH <逐n.JfB` .ЇP-@JfB` .ЇP-@-_g -Ї/ -Ї//./.N\`/-/-BBNJ(|p((|t(LN^.NuOAD_DEB SYSTEM.DEBUG2 SYSTEM.DEBUGNVH nCJp"S@n2&n (nBBgHnN gZB /, N BgN FBgN >HH(BgN v0H* f&.B</BgN&B /, N ~//N LN^ _ NOAD_UNPNVBgBgBHn</. /.Bg/.N g<NN^ _ NOAD_LLDNVH(n 0-F|>Jg,, .* Ю(H//<N ( Д-@`,.(.H//<N p-_?//?<N6 .P/N LN^ _NNSTALL_NVH(n=n ~`/, N dBgN _BgN HH(BgN 0H-@Jg .Ѭ `<N .fBN 4(BN ,( GfAqB0pB5pB`ACZ 0z`BgN f_ .ARE EoHn?<?<HnN AC 0HnHzNdg(AqB0pp @A^B @AB`2HnHzN,gAqB0pB5pB`Aqpp| 5pgnBg?/.Hn @AHp @A^Hp</.Nd g<NN?. @A^/0 @A"0Ҽ/?<NPRGinoLLN^ _ NOADCODEkrni NVBBg/-BgN +_?<e/-/-?<NN^.NuAKESUPSNVH(m . R A T&@-kLN^ _ NINDMAINNVBg/-|NN0Hѭ|B</-|BgN+_?<g/-/-|?<NdBg/-tN0HѭtB</-tBgNF+_x?<{/-x/-t?<N*N^.NuREATEOPNV/Jmho@ mFhomFh0-hH.//<N .0<AHЭX"-ToT.N^.NuONFIG_DNV A0C ArC 0AC 0/NHnHm`/NBgHn0N g< N0HnHn/NfBgHnrN g<N/NBg/.Hn$/N;_F/./.Hm`/Nh-MgN/.$?-F/N/N n /B/.$0-FH//N  _ /N&/NN^ _PONOADSYS $ SYSTEM.UNPACK SYSTEM.OS SYSTEM.LLDN NV,_NUTN z+|T mT PVD@MN0HmHmNHm?- -tЭx//-NNިNRN]N (NuN^NuOADER NVHAT(HA<&HHn?-0-H".Ҁ// / N Jng<NLN^.NuEAD_PAGNV0.H H"-"Ҁ-A0.H H@J@=@/.NvAT0.HЈ-@ N^ _TONIND_SENNVH n-h .S/0-H/N ;@8-n p+@4;m:BF` ATIBBlRF Fo=mA-HA<-HBE n0-HА(BnJf<NHn?-0-HЄ//./.NJng<NxBGA0.HЈ&@Bn=knnZ Eo<NJ ATI ( 9s Jlf<N0,n0.ްm8o`RERG`(-L`HLN^.NuPEN_FILNVH(n| @=@~`84p@k|nAP2IDA0 <f 4pAFRGinoLN^.NuHIFTNAMNVH(n @:JEnBn`pp4A4P@R@H. Eo U@<`BFJFo$ R@4A T@4BRBHށSF`Jl D./0.H/N =@LN^ _\ONDHASH NV~H n CJp"S@n2BA&/Nb 8<-HnNBgHn?-N>H/p6/NNBp6/A/NdACp S@n0HnN^J.gHHnHnN .Wgz n/B?.N~  _ `SFRGmfBGBNJFfELN^ _PONOOKUP_ENVH;n ;m?.?-N;nBNAT(HJg<N;l~+l";l ;l;l;lB?,N&_+S&+k*+k.LN^.NuNITMEDINVBg/.HnNr_n .gB/.N-_N^.NuPENINPUNVH(.BGBF Go<N AT:0JEf<N EHl@ ATH"Ұ n n Jf<NHH " n ``RGE`LN^ _ NIND_POSNV-m4/.0-H/N+_4J4]2-8H4]g<N&0-H/-4/Nl .;@: -4g/-4HnHnN/.NN^.NuILLBUF NV0-:mf -4R2-H//NNT0-:ATpRm:N^NuETBYTE NVHBgNHH<BgNH>JGl H м> G=@LN^NuETWORD NVHBgN0H//<N~,BgN0H.Jl޼ Ї-@LN^NuETLONG NVH,. 0-m:>HǼl>JGo0-:ATA//.H/N$H߮Hǜm:0-HnJ4]2-8H4]g<N -4R/HnHnNn-nA<(H/0-H/N*l-EJoZHn?-0-H".Ҁ/?././ NJng<N0-H/./NV(ٮ .Ѯ .ѭ4`:Jo -4R2-H//N"NhJfLN^ _PONOVEMULT//0/2/ AH@B@2/Ё/@" /WXNu// /"/ N2/A" /WXNu// /"/ N/@" /WXNuH>*jD,jD$&BBx㉰mRSDlJjDjDL|NuH0/ oC"4JBAR`$aJBBB`QQ oC"0/H#//IL._NuH oJB@BA"o JBBBlBA`$HR` fQ`RS@`?A"/oL\NuH o0/2/SA"o JBBA@m`Q/o L NuB`$_02 _ @o0 Ao*BBAm"6@SCBoSA`@"H`RCoN$_0"_ _J/ S@m*BABB@m6B$I”@`!Q`QNuHr`HBA oJ"oJB@f`fQ AA/oL\NuH"o J oJv`:H"o J oJBC`&H o J"oJv`H o J"oJBCB@BA@m4`4`fQ@n C`cC"/oL\NuNuNuJoNu@ [MacSupplement 2&;f/Nt0. @ g0@#g2S@g6U@g:_@ [ *`$%kT$k [ &$Dz?`LLrTp `  /3 7,!M"Y8#u $%&'<($) *\+ ,c,-y(.t/801>  rootcatalogːHp8@ _#CW [  ramdisk/RAMDef.textf.textramdisk/StuffBoot.textoot.texTlAsm/GrafEqu.Texth.TexthTlAsm/PrEqu.Texthexthramdisk/info.texthtextile( ramdisk/RAMDisk.textsk.text TRANSFER.OBJ"hOBJ̍"TlAsm/FSEqu.Texthexthtty/term.menus.textmenus.te$Transfer/config.textconfig.t#ramdisk/ChangeQ.texteQ.text ramdisk/FixSP.texth.texth TlAsm/ResEqu.TexthTexthTlAsm/SysMacs.Texth.Texth MACCOM.OBJ"haa$ TlAsm/GrafTypes.Textes.TextTlAsm/SysErr.TexthTexthTlAsm/ToolEqu.Texth.Texth defprocs/BUTCDEF.TEXTDEF.TEXTTlAsm/MocPasLib.Textib.TextTlAsm/SysEqu.TexthTexthTlAsm/HeapDefs.Texts.TextTLASM/PACKEQU.TEXTh.TEXThTlAsm/SaneMacs.Texts.Textdefprocs/wdef.textN N^.TlAsm/ToolMacs.Texts.Text!TLASM/PACKMACS.TEXTS.TEXTMAC.BOOT"hH́RAMDISK/EXEC.TEXThTEXT TlAsm/QuickMacs.Textcs.Textdefprocs/mdef.textN N^.ramdisk/RAMStart.textart.textdefprocs/BUTCDEF.TEXTDEF.TEXTΝ@ [&O͝+PO& L&defprocs/mdef.textN N^.@ [&N/'N4* r*defprocs/wdef.textN N^.@ [&N^+ZNd8 8MAC.BOOT"hH́Ν@ [&瘝+  MACCOM.OBJ"haa$Ν@ [&`,0 0ramdisk/ChangeQ.texteQ.textΝ@ [&Ӳ +]Ӳ   RAMDISK/EXEC.TEXThTEXTΝ@ [& C|# ramdisk/FixSP.texth.texthΝ@ [&+b ramdisk/info.texthtextile(Ν@ [&, ramdisk/RAMDef.textf.textΝ@ [&ӵ+hӵ" ramdisk/RAMDisk.textsk.textΝ@ [&Ӳ+lӲ ramdisk/RAMStart.textart.textΝ@ [&+o /ramdisk/StuffBoot.textoot.texΝ@ [&Ӳl,sӲp 3TlAsm/FSEqu.TexthexthΝ@ [&`D+w`J 7TlAsm/GrafEqu.Texth.TexthΝ@ [&`P^`T M TlAsm/GrafTypes.Textes.TextΝ@ [&`Z+`e YTlAsm/HeapDefs.Texts.TextΝ@ [&`j+`o uTlAsm/MocPasLib.Textib.TextΝ@ [&`u+`x TLASM/PACKEQU.TEXTh.TEXThΝ@ [&+ TLASM/PACKMACS.TEXTS.TEXTΝ@ [& +  TlAsm/PrEqu.TexthexthΝ@ [&0;+0@ TlAsm/QuickMacs.Textcs.TextΝ@ [&`܌+`ܐ TlAsm/ResEqu.TexthTexthΝ@ [&`ܗ+`ܝ TlAsm/SaneMacs.Texts.TextΝ@ [&`ܣ+`ܮ. .TlAsm/SysEqu.TexthTexthΝ@ [&`ܴ^`V  VTlAsm/SysErr.TexthTexthΝ@ [&`Ν+` cTlAsm/SysMacs.Texth.TexthΝ@ [&`ܝ+` yTlAsm/ToolEqu.Texth.TexthΝ@ [&`+`: :TlAsm/ToolMacs.Texts.TextΝ@ [&`+`  TRANSFER.OBJ"hOBJ̍Ν@ [&n,n 1H0hPASLIB UNITSTD GRAFUTILUNITHZ STORAGE QUICKDRAHWINT FEDEC FONTMGR EVENTS WINDOWS FOLDERS MENUS FLDUT WMLSTD WMLCRS WMLGROW WMLSB INTERNATALERTMGRUNITFF UNITCS UNITFILEUNITFMT FMGRUTIL*PMM +PMDECL ,SYS1LOCK.CPDEV 0CPPROCS 1DBENV ?FIELDEDIGSCRAP IFILERCOMKPRMGR MPRMGRUTINPRFILE OPRSTD PCIDEV QCIPROCS RRHDEV SRHPROCS TPRPROCS UPRBUF VSTDUNIT XBLKIOINTfBLOCKIO gPASHEAP h.N Xl$"F&(J (3*N$N&N&vN&@N&N&XN& N&N& N& *N& zN&N(XN(N(nN( N(&N*rN*N*:N*N*xN*zN*"X/NњPASLIB1 INTRColdNHzSegPxHz FmgrUtilCP fvhSgAl WMCold SegHotSc!SegColdS"SegPxScr#WMWarm &WMJrnl 'SYSINIT A(m$BgNPMMSeg CHOTSEG D$BgNGRAFSEG EH(m$fldsel FSegFldEdGPrBtn JPrMgrMscLPrMgr MPr PCi QRh RPASIOLIB`SULib cMainProg l$"NV,_NU\"A^C: 0HmHm^A4/"JN"N]"NuN^NuERMINAL SYS_TERMINATEdMainProgTERM "F&JoNVBgHm g`0-gU@gS@g W@gS@g` `Hm` n0?B. ` mfHm n0| N^.NuEADCH JoNVBgHnNpg*0.@Ng@ g@g@ g` B.`|0.k|nA02IDA0 <fN^NuES @@JoNVH&m$Hn/+젊=| nBBgHnN gB. `0.mf n@J@or n"n@0A=A/. n@??<"(kBg?.> D@?BgHn?,*?, l*??,Hn`P n mH?.p n@ @l( n//.HnHn?<" _Cp@ S@n0.mf| /.LN^.NuETREPLYJoNVBgBgN^NuIDETHEBJoNV/ nCJp@"S@n(m$Hn/,젊?-Bg lHh l0-h? l0-h?Hn/.(_N^.NuRAWTHEBJoNVH(nBgHnNgdBT.@=@~`DA0p@ @0\A0pA A9_gp A0pA|0@8RGino| `B. LN^.NuETNUMBEJoNV n CJp@"S@n-gD?.A/zHnHzHnHzHn?<"ACp@ S@n|`Hn m$/(젊Jng4?.A/zHnHzHnHzHn?<"HnN0`HnHzTHn?<"HnNBgHnN  n W@gN/.N^ _\ONARNING @; to continue); to continue (Err# ) (Err# JoNVH(nBG` @BRG GoLN^.NuLANK_BUJoNV/. ?-r/-x/.Hn<B"l n JPoHz< n ?NB-| g=||*HnN |N^ _PONUT_ON_DError: Write to disk failed; JoNV/ mI/. 0,\@2. m@?0X@.H-HB@0-A?(_N^ _PONETPOSN JoNVHn?.. NHn?. .Nv/.?.0.m?0-n?0-n?N^ _ NETTEXTRJoNV/-ꠊ?< |0-S@?0-mS@?Bg0-S@D@?- @-gB m$ (П+@`B m$ (П+@N^NuLINKCARJoNVH n CJp"S@n nCJp"S@nB.~ n@Gm& n0p@ @ n/.??<"`RG` n@<JFf`V=F~`F n0p@k|nA`2IDA0 <f n "n1pA| RGino n0`@ @.f&/.??<" n@J@^D@` n@<JFf` n0`@ @-f`Hz/.",J_f( n/Hn/.Hn?<" _Cp@ S@nHn/.",>JGW.A$ARBGVg8.@Fnn( n//.HnHn?<" _Cp@ S@n|LN^ _NHECKTIT-JoNV/.HzJHn?<"ACp@ S@nB. HnNFBgNRg| N^.NuVERWRIT(' already exists. Overwrite it? (Y or N)JoNV/.- "gB-gNHzNBgHnNRgBgHn?<PHzHzN.gACp@ S@nHnHnBg"F0.g @zg6`HnHnHmr?:"|Jnf |~` Hzh?.Nd`\BgHnNg@ACp@ S@nHnHnHmr?:."|JnoHz?.N`|~` Hz?.N-g/-xNBHn?-r/-x/<Hn<B"lJno(HzJ?.NHz BgNHn?-r"8BB-Hn?-r"BJno*Hz?.NHzBgNHn?-r"8BB-BN(  -gFB--] gHn0<vH/NHn?-r"8;|t;|v;|r|]Hm:?<G.N^ _TONETRECOR4Terminating Receive atempt./Error positioning File pointer in receive file;Terminating Receive atempt./Error positioning File pointer in receive file;'Error: Could not make the record file; #Error: Could not open record file; "Error: Could not open record file;.TEXTWrite to Filename [.text]? JoNVnmHm:?<.Hm:?<. N^ _TONETISFILJoNVH.- "gnB-gNHzNBgHnNgHBgHn?<PHzHzNg.HmHn?<R<JFf |~` Hz?NN  -g0-|  m4W@g Hz>BgNB-HmBg(Hm:?<GLN^ _TONETPLAYBRTransfer Complete.Warning: File not Found.TEXTRead from Filename [.text]? JoNV/-gNHn?--?--NtHnm-`HHn?-N?.?.H CA/0-S@?0-mR@?Ri.o.N^NuAINTSCRJoNVH. :.Hn?-. ?-NHnBg D@?/-誠lH E@. `.H H"ECAECp! S@nRi.oH ER@F` H CACbp! S@nRi.oLN^ _\ONCROLLUPJoNVHn?. . ?.. NHn0. nn . H2. @A Rn `N^ _\ONRASELINJoNVH.. f?. ?.Nx`~?. ?-NhH R@lVHn?-?-H S@NpHnH S@@` H CACbp! S@nRi.o?-?.NLN^ _PONRASESCRJoNV;m-H-HAnl--?.N`-H2.@AN^ _TONEWLINE JoNV/>.Hn?--?--NHn-H2-@A G ]mWg |@HH@J@?Hn2`?0-mlRm.N^ _TONRAW JoNVH nCJpK"S@n2A(H/-ꠊ-gNJ0.S@=@BG`?-?-A0pHg_@gS@g(S@g>S@grW@g^`vN"`/<p(/P`Bg?-0-S@?;_`Bg?-0-mP@H@m?;_`^;m?<N.`N?<N$`D- gA0pH=@B?.NV` A0pH @lA0pH?N4Hm?--NxRGinoB m$ (П+@LN^.NuISPLAY JoNVH(n B.HnHn?<+" &n-nBF0S@=@BG`> n0p  \ _  W  W‚  W‚g A`RFRGino8 . W n  Wg>0S@=@~` S@ACpRGinoSTJTo0S@ nC8 S@=@BG`fA 0 pf@ R@A 0 f. R@"UA=A<` R@AC`RFinoST`A 0 pf A pRGinoBF0S@=@BG`6A 0 pfBD` D RD DoPF` Ap`RFRGino8JTo 0S@ nLN^ _NILTERINJoNVHA&HBnBG(n0S@=@BF`>t` n\ n _ n W n^g A`pRGRFino8HnHl?" LN^.NuOSS_TRAJoNVH| Hn?-.A T//<Hn<B"JnoHz?.N`JnB. `A(H<. S@=@BG`@BnApp m0o non no=|ApRGino=FHnN n0-g"A T/ .T/ n/HmqN` n0Hn nHh?" nJPo| -|gHnNLN^.NuETCHCH Error reading from serial portJoNVBg/.N_ N^.NuECEIVE JoNV/ n CJp "S@n2(n.gX n@\ n__g 0.|@8`6 na\ nz_g0.|aR@8`0.mf8`8`r .Ff8 `d ./f8`V ."f8+`H .#f8*`: .'f8/`, .+f8,`0.m ]Jn^g8`8(_N^ _PONOKEYEVEJoNV0.mf`0.m f?< /</</<N:`Hn?-.A R/p/Hn<B"lJno6Hzh?.N nf" m2f?</</</<N: m4f-|g=|n HnNN^ _TONEND Error writing to serial portJoNV/=| p Hm趠4g BgN`vB mfHmHm|?<Hm趠R=_Jng6 nPW nWg BgN|`"`HzJ?.NBgNd` -|@J@f;| |pA| `HnHm|-|@R@?"Hn?-.A| R/-|@H/Hn<B"lJno>Hz?.NX nf" m2f?</</</<N:BgN``B0-HП+@ m4fF-|g@-|@=@=n~`A|0p@"SAARGinoHnN.N^NuENDTHEF6Error writing to serial portError reading the fileJoNVH(mx -xм&@/./<N nJPo`4 n 0/-xN nf|]`/ / 0.R@?" B-]LN^ _ NLUSH_BUJohNVdH(nB n0S@HЭx&@ -xм-@n TW + Wg 8`:` Tg|A-HrBG` nr @r!RG Go0.S@=@fBG` n 0 pf RF @=RGinfo FobBnz>`V @26TRA AlBz @26RA> n /0R@Hs?" n n Hpp n /?." ~8SGJGl  gV0|=@d>`B 3 pf6zBn| R@8J3@g nn0.|@B3@Rn|RD`0.|S@8~SGindl  g0R@ 8 n / nn0R@Hp?." 0.T n PfHm/.?N`* n0HЭx&@ nn// 0R@?" nRPLN^ _NROCESS_JoNVH&nB-]0-vS@HЭx(@> mt @mHmvHmtHk?N`Hk0-tR@Ht?" mtLN^.NuUT_IN_BJoNV/>.-gNJ0. U@k @nH0;N0S@k @ nH0;NJJ~&~Zj~p- N`X-| @|Hm:?<-| `4 GWDN `$- N\`NL`HnB"j"`:JGg?NX`.JGg?N^`"JGg?NR`JGg?NF` JGg?N@Bg*.N^.NuENUCOMMJoNVH(m$+m/-0-S@gg-gHnN`&-gN<`-gHmBgNB-```,N^NuOOP Creation of data seg failed: ">MainProgTERMINIT (JoNVHmHmBg"FHmHmHm?:d"||;|;| ;|;|;|Hm?-A/p /Hm<B"lHm?-犠"8N^NuREATEDEJoNVHmHmHm?:|"|JmoHmHm抠"NF`Pm;m~;m;m;m;mHm?-A/p /Hm<B"lHm?-犠"8N^NuPDATEDEJoNV/ (m$HnB"jHn"Jn)l)l/,/.L>)nB"j>\Bj-g*-] gHm0<vH/NHn?-r"8-g HmBg(Jm.m Hn?-."8Hn/-Hn"Jnn Hn?.",Hn?<Hn"Jnn Hn?.",Hn?<Hn"Jnn Hn?.",?<<!NL(_N^NuUIT JoNV n CJp@"S@n/-  /- HzBg/- HnBg g/- HzhBg/- /.?</- Hz8Bg/-  /-HnB"j"N^ _PONATAL (CR to terminate. FATAL ERROR: JoNVHz 0.H/NN^ _\ONEAPERRO,*The heap is full. Program must terminate.JoNVHz 0.H/NN^ _TONRAFERR .,QuickDraw has died. Program must terminate.JoNV|Bg?< -HS@|?0@;|Bg?<0-S@|P?;_m;mm;m-?--?-NN^NuNITSCREJoNVHnB"jHn"JnoHz0.H/NpA0A A-g"HzHnHzHn?<"HnBNHn?<?<"Hn?<HzVHn",Hn"ACp S@nHz0HmHn?<"ACp S@nN^NuETPROGVN--"(Found unrecognizable program path name "Can't get info on my processJoNVHtNHnHmHzHnp?<"Hnp?<R<JFg4HzzHmHz^Hn>?<"Hn>Hn?<"HnH/Nj~`Hn AHp>PRG GoLN^NuETUPMEN:tty/TERM.MENUS.TEXTCan't find menus tty/TERM.MENUS.TEXTJoNV;|;| ;|;|;|;|;|;| B-qN^NuNITCHRSJoNVBmB-B-BgHmHnHnv gHzH0.H/Nt0.n| ;@0.mnH;@;nN^NuNITDESK"!Can't get metrics for System fontJoNVH&m$ kIHn?,??,?,BHnHz<</+BB"j?<PL./L LN^NuEFRESHSJoNVHmHmHm?:"|JmgN.`,Hm?-A/p /Hm<B"Hm?-犠"8m;m~;m;m;m;m-N?-~NX?-N^?-NR?-NF?-N@N^NuETDEFAUJoNVH&m$NHn?<"ACt 0HnHn/<N BHnHm?<<":/- -мN /AR/l mY/A/>D/+LB"j'_N>B-;|=mmB.BgHnHnHnv gHz0.H/N0.n2.@;A0.Hn;@0-m;@;nN&| kIHn0,P@?0|$?0,Q@|?0,||? kIHn0,D@?0D@?"BHnHz</+BB"j?<PL+_/-BLh/-ꠊ?-?:NNB+_B-/-ꠊB-B-B-BmBBgNBgN ;|.Bm6Bm8Bm0Bm2Bm4AC:p S@n0N~` Aa RG GoLN^NuNITTERMLTransfer/config.textTransferCan't get metrics for MainFontTermHeapJoNVACb =| /.Hn/. /. Hn/.?.<": nJPo n` n/NN^ _NAKEFTRA TTY/Dataseg MainProgTERMCMD *JoNVHz^NBgHnN_NJn\.g,;nJnfHm:?<Bg`Hm:?<<N^NuETLINED.,Set Delay between Lines (in milliseconds) ? JoNV0.S@k @nH0;N"*2:BJRZbjrz=|2 `v=|K `n=|n `f=| `^=| `V=| `N=|, `F=|X `>=| `6=| `.=| `&=| ` `=| `=| `=|% `=|K N^ _TONPEEDS JoNV=|=n-n-n -nHnHm HnҠ"VJno Hm Hz.Hn?<"Hn?.NN^ _NOCONTRO can't be set upJoNV n W n 3. "6F^5PͪH r^E1!1!O; ;File ButCDef.TEXT ;-------------------------------------------------------------------------- ; ; Standard Button Definition Procedure for the ; MacIntosh Control Manager ; ; written by Andy Hertzfeld August, 1982 ; ; (c) 1982 by Apple Computer, Inc. All rights reserved. ; ; This file contains the control definition procedures ; that define the standard "button" type controls. These ; include PushButtons, CheckBoxes, and a checkBox variant called ; RadioButton ; ; Modification History: ; ; 22-Aug-82 AJH Added clipping, centering to PushButProc ; 25-Aug-82 AJH Fixed corner-clobber bug in pushButProc ; 29-Aug-82 AJH Added "255" hiliting, ; 29-Sep-82 AJH Added CheckBox control definition procedure ; 03-Oct-82 AJH Fixed bug in scrollBar positioning -- wasn't ctl relative ; 05-Oct-82 AJH Fixed checkBox flashing, added code saving optimizations ; 10-Oct-82 AJH Converted for QuickDraw Trap Interface ; 17-Oct-82 AJH Made controlProcs preserve A1 ; 14-Nov-82 AJH Improved PushButton roundness scaling; removed box in arrowBits ; 16-Nov-82 AJH Made branch tables offset based ; 28-Dec-82 AJH Put button definitions in their own file ; 11-Mar-83 AJH fixed up check box drawing ; 27-Mar-83 AJH made it respect initial clip in button drawing ; 01-Apr-83 AJH made it use hardwired gray ; 04-Apr-83 AJH made it force size 12 for text ; 07-Jun-83 AJH fixed scrambling bug, changed check draw for new QuickDraw ; 29-Aug-83 AJH fixed scrambling bug in CalcPBut ; 27-Sep-83 AJH made variants > 7 not force the system font ; 12-Oct-83 AJH changed button disabling ; 17-Oct-83 AJH back to "gray-out" button disabling ; 31-Dec-83 AJH made text of checkBox/radioButttons grayed out if disabled ; ;---------------------------------------------------------------------------- 0.INCLUDE TlAsm/SYSEQU.TEXT 0.INCLUDE TlAsm/SYSMACS.TEXT 0.INCLUDE TlAsm/GRAFEQU.TEXT 0.INCLUDE TlAsm/GRAFTYPES.TEXT 0.INCLUDE TlAsm/TOOLEQU.TEXT 0.INCLUDE TlAsm/RESEQU.TEXT 0.INCLUDE TlAsm/QuickMacs.TEXT 0.INCLUDE TlAsm/ToolMacs.TEXT ; 0.PROC BDEF,0 ; ; FUNCTION PushButProc( selector: INTEGER; ; theControl: ControlHandle; ; message: INTEGER; ; param: LongInt): LongInt; ; ; PushButProc is the control definition procedure for simple pushButtons, one of the ; standard control types supported by the user interface toolBox. mon ; SavePen .EQU -20 IndicatorRect .EQU -30 ; 0BRA.S @0 ;skip header ; standard header 0.WORD 0 ;flags 0.ASCII 'CDEF' 0.WORD 0 0.WORD 1 ;version # @0 0LINK A6,#-30 ;set up a stack frame to address parameters 0MOVEM.L D3-D7/A1-A4,-(SP) ;save work registers ; ; buttons only handle messages 0,1 and 2 ; /CMP #3,12(A6) ;inspect message value /BGE.S DoneP1 ;if >2, nothing to do ; ; save the penState and set it our way ; 0PEA SavePen(A6) ;push pointer to savePenState 0_GetPenState ;remember current penState 0_PenNormal ;set the pen the way we want it ; ; fetch the parameters into registers ; 0LEA 8(A6),A0 ;get ptr to first parameter 0MOVE.L (A0)+,D3 ;get param in D3 0MOVE.W (A0)+,D0 ;get message 0MOVE.L (A0)+,A3 ;get the control handle 0MOVE.W (A0)+,D6 ;get selection index 0MOVE.W D6,D7 ;remember raw selection code 0AND #7,D6 ;strip high part of selection code 0CLR.L (A0) ;clear out function result 0MOVE.L (A3),A0 ;get control pointer in A0 ; ; case out on the message number ; 0ADD D0,D0 ;double for word index 0LEA GoPushBut,A1 ;get table address 0ADD 0(A1,D0),A1 ;compute dispatch address 0JSR (A1) ;dispatch to appropriate routine ; ; restore original pen state ; 0PEA SavePen(A6) ;push savePenState 0_SetPenState ;restore original pen state ; ; we're done -- restore registers and return to caller ; DoneP1 0MOVEM.L (SP)+,D3-D7/A1-A4 ;restore work registers 0UNLK A6 ;unlink stack frame TenBytExit MOVE.L (SP)+,A0 ;get return address 0ADD #12,SP ;strip parameters 0JMP (A0) ;return to caller ; ; PushButProc dispatch table -- entries must be long branches! ; GoPushBut 0.WORD DrawPBut-GoPushBut ;draw is message 0 0.WORD HitPBut-GoPushBut ;hit test is message 1 0.WORD CalcPBut-GoPushBut ;calc regions is message 2 ButStub RTS ; ; DrawPBut draws the pushButton ; DrawPBut 0TST.B ContrlVis(A0) ;is it visible? 0BEQ.S ButStub ;if not, we're done ; ; calculate roundness as function of rectangle size ; 0BSR RoundCalc ;compute roundNess factor in D4 ; ; erase the bounding rectangle (if necessary) ; 0LEA ContrlRect(A0),A4 ;get pointer to bounding rect 0TST.B D6 ;is it a pushButton? 0BEQ.S EraseCBound ;push buttons are always erased 0TST.B D3 ;draw all? 0BNE.S SkipCErase ;if not, don't bother to erase ; EraseCBound 0MOVE.L A4,-(SP) ;push rect 0MOVE.L D4,-(SP) ;push rounding factor 0_EraseRoundRect ;paint it the background color ; ; save the current font and force the system font ; SkipCErase 0MOVE.L LGlobals(A5),A0 ;get LisaGrafGlobals base 0MOVE.L ThePort(A0),A0 ;get current port 0MOVE.L txFont(A0),D3 ;remember the font,face 0MOVE D7,D0 ;save selection code 0MOVE.W txSize(A0),D7 ;remember the size 0SUBQ #8,D0 ;was code 8 or greater? 0BGE.S @1 ;if so, use window's font 0CLR.L txFont(A0) ;force system font, normal face 0MOVE #12,TxSize(A0) ;force size = 12 @1 0MOVE.L ClipRgn(A0),-(SP) ;push the current clipRgn handle ; ; save old clip region and clip to the bounding rectangle sected with oldClip ; 0CLR.L -(SP) ;make space for region handle 0_NewRgn ;allocate a region 0MOVE.L (SP),A2 ;remember region but leave on stack 0_GetClip ;remember the current clipRgn 0MOVE.L (A3),A0 ;get control pointer 0PEA ContrlRect(A0) ;push pointer to its bounding rect 0_ClipRect ;make that the clipping region 0MOVE.L A2,-(SP) ;push the old ClipRgn 0MOVE.L 4(SP),-(SP) ;the answer goes into current clip 0_SectRgn ;intersect new and old ; ; get a pointer to the title string and push it ; 0MOVE.L (A3),A0 ;get control pointer 0PEA ContrlTitle(A0) ;point to title string ; ; position the pen to center the string in its rectangle ; 0CLR.W -(SP) ;make room for function result 0PEA ContrlTitle(A0) ;point to title string 0_StringWidth ;Get width of string 0MOVE.W (SP)+, D0 ;String width in D0 ; 0MOVE.L (A3),A0 ;handle -> pointer 0LEA ContrlRect(A0),A4 ;set up pointer to bounding rect 0TST D6 ;is it a checkBox? 0BNE PosCheck ;checkBoxes center differently ; 0MOVE RIGHT(A4),D1 ;get right coordinate 0SUB LEFT(A4),D1 ;get width of button 0SUB D0,D1 ;get buttonWidth -stringWidth 0ASR #1,D1 ;divide by 2 0ADD LEFT(A4),D1 ;add to left for starting X ; DrawBTitle 0MOVE.W D1, -(SP) ;push left coordinate ; 0MOVE.W Bottom(A4), D0 ;Get bottom coordinate 0MOVE D0,D1 ;remember in D1 0SUB.W Top(A4),D0 ;get height 0SUB #16,D0 ;subtract 16 0ASR #1,D0 ;divide by 2 0SUB D0,D1 ;compute centered baseline 0SUBQ #4,D1 ;leave 4 for descenders 0MOVE.W D1, -(SP) ;Push it 0MOVE.W D1,D5 ;remember y position 0_MoveTo ;Move the pen there 0_DrawString ;draw it ; ; restore original font, face and size ; 0MOVE.L LGlobals(A5),A0 ;get LisaGrafGlobals base 0MOVE.L ThePort(A0),A0 ;get current port 0MOVE.L D3,txFont(A0) ;restore the font,face 0MOVE.W D7,TxSize(A0) ;restore the size 0TST D6 ;is it a checkBox? 0BNE PlotCheck ;if so, go draw it ; 0MOVE.L A4,-(SP) ;push the rectangle pointer 0MOVE.L D4,-(SP) ;push rounding factor 0_FrameRoundRect ;frame the button ; ; hilite the button if necessary ; 0MOVE.L (A3),A0 ;get control pointer 0MOVE.B ContrlHilite(A0),D0 ;is it hilited? 0BEQ.S DoneDrwBut ;if not, we're done ; 0CMP.B #$FE,D0 ;is it the special hilite state? 0BHS.S SpecialHilite ;if so, go do it ; 0MOVE.L A4,-(SP) ;push rectangle 0MOVE.L D4,-(SP) ;push rounding factor 0_InverRoundRect ;hilite by inverting ; ; restore original clipping region and we're done ; DoneDrwBut 0_PenNormal ;set the pen back to normal 0MOVE.L A2,-(SP) ;push old clip region 0_SetClip ;restore it 0MOVE.L A2,-(SP) ;dispose of temporary region 0_DisposRgn ;de-allocate it 0RTS ;all done! ; ; SpecialHilite handles drawing the disabled button SpecialHilite /BSR.S DisableText /BRA.S DoneDrwBut DisableText /MOVE.L A4,-(SP) ;push rectangle /MOVE.L #$00010003,-(SP) /_InsetRect /MOVE.L A4,-(SP) /MOVE.L (A5),A0 /PEA Gray(A0) /_PenPat /MOVE #patBIC,-(SP) /_PenMode /_PaintRect ;gray it out /_PenNormal /MOVE.L A4,-(SP) /MOVE.L #$FFFFFFFD,-(SP) /_InsetRect /RTS ; ; PosCheck does horizontal position for check box buttons. It computes the position ; in D1 and dives back into common code ; PosCheck 0MOVE.W Left(A4),D1 ;get the left edge 0ADD.W #18,D1 ;leave room for check box 0BRA.S DrawBTitle ;back to common code ; ; RoundCalc calculates the rounding factor in D4 based on the control's rect ; RoundCalc 0TST D6 ;is it a checkBox? 0BNE.S CheckRound ;if so, special case it ; 0MOVE.W ContrlRect+Bottom(A0),D4 ;get bottom coordinate 0SUB.W ContrlRect+Top(A0),D4 ;figure out vertical height 0LSR #1,D4 ;scale it down by a factor of 2 0MOVE D4,D0 ;fill both halves with it 0SWAP D4 ;get in high part 0MOVE D0,D4 ;and in low part 0RTS ; CheckRound MOVEQ #0,D4 ;checkBoxes are square! 0RTS ; ; HitPBut handles the button hit-test ; HitPBut 0MOVE.B ContrlHilite(A0),D0 ;get hiliteState 0ADDQ.B #1,D0 ;is it 255? 0BEQ.S @1 ;if so, skip 0ADDQ.B #1,D0 ;how about 254? 0BEQ.S Return254 ;if so, we're done ; 0CLR.W -(SP) ;make room for function result 0MOVE.L D3,-(SP) ;push the point 0PEA ContrlRect(A0) ;push address of rect 0_PtInRect ;in the rectangle? 0TST.B (SP)+ ;examine result 0BEQ.S @1 ;if not, we're done 0MOVE #inButton,22(A6) ;return that it was 0TST D6 ;a checkBox? 0BEQ.S @1 ;if not, we're done 0ADDQ #1,22(A6) ;if so, flag it @1 RTS Return254 0MOVE #254,22(A6) ;indicate its 254-disabled 0RTS ; ; CalcPBut returns the bounding region of the button ; CalcPBut 0TST D6 ;is it a checkBox? 0BNE.S CalcSquare ;check box bounds are just rects ; 0BSR.S RoundCalc ;calculate rounding factor 0_HidePen ;dont draw anything 0_OpenRgn 0BSET #7,(A3) ;lock it down 0MOVE.L (A3),A0 ;get pointer to control 0PEA ContrlRect(A0) ;push rectangle pointer 0MOVE.L D4,-(SP) ;push rounding factor 0_FrameRoundRect ;frame the button 0MOVE.L D3,-(SP) ;push the region 0_CloseRgn ;make the rounded rectangular region 0_ShowPen 0BCLR #7,(A3) ;unlock the control ; ; set the pattern for indicator dragging ; DragGray 0MOVE.L (A5),A0 ;get qDraw globals 0LEA Gray(A0),A0 ;point to gray pattern 0MOVE.L (A0)+,DragPattern ;move in the 1st half 0MOVE.L (A0),DragPattern+4 ;move in the 2nd half 0RTS ;all done! ; CalcSquare 0MOVE.L D3,-(SP) ;push the region 0PEA ContrlRect(A0) ;push the rectangle pointer 0_RectRgn ;make a rectangulare region 0BRA.S DragGray ;all done -- go set drag pattern ; ; PlotCheck takes care of drawing the actual check box of the check box button. It ; figures out where to draw the box, draws it, and then checks it or not based on ; the current value and hilite state of the button ; PlotCheck 0SUBQ #8,SP ;allocate a rectangle on the stack 0ADDQ #2,D5 ;bump down a little 0MOVE D5,Bottom(SP) ;set up the bottom 0SUB #12,D5 ;compute the top 0MOVE D5,Top(SP) ;set up the top 0MOVE Left(A4),D5 ;get left edge of boundsRect 0ADDQ #2,D5 ;indent 2 pixels 0MOVE D5,Left(SP) ;that's the left of the checkRect 0ADD #12,D5 ;compute right edge 0MOVE D5,Right(SP) ;update the right edge ; ; erase the check box ; 0MOVE.L SP,-(SP) ;push rectangle pointer 0_EraseRect ;erase it ; ; OK, now we must fill in the checkBox rectangle based on the value and hilite state ; of the control ; 0MOVE.L (A3),A0 ;get control handle 0MOVE.W ContrlValue(A0),D5 ;get the value 0MOVE.B ContrlHilite(A0),D0 ;is it hilited? 0BEQ.S FrameCheck ;if not, skip ; ; its hilited so up the penSize to indicate its hilited ; 0CMP.B #$FE,D0 ;disabled? 0BLO.S SkipDis ;if so, skip doubling ; 0BSR DisableText 0BRA.S FrameCheck SkipDis 0MOVE.L #$00020002,-(SP) 0_PenSize ;up the penSize FrameCheck 0MOVE.L SP,-(SP) ;push the rectangle 0CMP.W #2,D6 ;test for radio button 0BEQ.S @1 ;if its a radio button, go do it 0_FrameRect ;frame it 0BRA.S @2 @1 0_FrameOval @2 0_PenNormal ; ; now we can draw the check if we're supposed to ; 0LSR #1,D5 ;check out the low bit of D5 0BCC.S DonePCheck ;if its off, we're done ; 0CMP.W #2,D6 ;test for radio button 0BEQ.S DrawRButton ;if its a radio button, go do it ; 0MOVE.L SP,-(SP) ;push the rectangle pointer 0MOVE.L OneOne,-(SP) ;push the inset factor 0_InsetRect ;inset the rectangle 0MOVE.L TopLeft(SP),-(SP) ;push top left 0_MoveTo ;move to it 0MOVE.L BotRight(SP),-(SP) ;push bottom right 0_LineTo ;draw one line of the cross ; 0MOVE Right(SP),-(SP) ;push right 0MOVE Top+2(SP),-(SP) ;push top 0SUBQ #1,(SP) ;bias the top 0_MoveTo ;move to it 0MOVE Left(SP),-(SP) ;push left 0SUBQ #1,(SP) ;bias the left 0MOVE Bottom+2(SP),-(SP) ;push bottom 0_LineTo ;draw the line 0BRA.S DonePCheck ; ; draw the radio button check mark -- a little circle ; DrawRButton 0MOVE.L SP,-(SP) ;push pointer to rect 0MOVE.L #$00030003,-(SP) ;push inset factor 0_InsetRect ;inset it 0MOVE.L SP,-(SP) ;push rect again 0_PaintOval ;draw the circle? ; DonePCheck 0ADDQ #8,SP ;pop off the rectangle 0BRA DoneDrwBut ;all done! /.END 3. "6F^5PH r^!!N/;File mDefProc.Text ;------------------------------------------------------------ ; ; Standard Menu Definition Procedure for Text Menus ; ; written by Andy Hertzfeld July 1982 ; ; Here is the default menu definition procedure for text menus. It knows how to ; draw a text menu, or select from within a text menu. It is always called from the ; window manager port with clipping set to the menuRect. ; ; MODIFICATION HISTORY: ; ; 27-Dec-82 AJH Broke off into separate file for resources ; 28-Jan-83 AJH made "GrayRect" use FillRect and a hardwired gray ; 17-Mar-83 AJH Fixed 4 pixel choosing offset ; 17-Mar-83 AJH no more forcing bold ; 28-Apr-83 AJH added "calcMenuSize" message ; 30-Oct-83 AJH changed disabling ; 06-Nov-83 AJH back to old disabling; special-cased "-" item ; 13-Feb-84 AJH speeded up CalcMenuSize message (linear instead of N squared) ; ;--------------------------------------------------------------- 0.INCLUDE TlAsm/SYSEQU.TEXT 0.INCLUDE TlAsm/SYSMACS.TEXT 0.INCLUDE TlAsm/GrafTypes.TEXT 0.INCLUDE TlAsm/ToolEqu.TEXT 0.INCLUDE TlAsm/ResEqu.Text 0.INCLUDE TlAsm/QuickMacs.TEXT 0.INCLUDE TlAsm/ToolMacs.TEXT 0.PROC MDEF,0 ; ; PROCEDURE TextMenuProc(message: INTEGER,menuHandle,menuRect,point,VAR whichItem:INTEGER); ; ; ; Stack Frame Definition for TextMenuProc ; MWHICHITEM .EQU 8 MPOINT .EQU MWHICHITEM+4 MMENURECT .EQU MPOINT+4 MMENUHANDLE .EQU MMENURECT+4 MMESSAGE .EQU MMENUHANDLE+4 ; 0BRA.S @0 ; standard header /.WORD 0 ;flags word /.ASCII 'MDEF' ;type /.WORD 0 ;ID /.WORD 2 ;version @0 0LINK A6,#0 ;set up a stack frame 0MOVEM.L D3-D7/A2-A4,-(SP) ;save a whole bunch of work registers 0MOVE.L MMENUHANDLE(A6),A3 ;keep menuHandle in A3 ; 0MOVE MMESSAGE(A6),D0 ;draw or choose or calc? 0BEQ DRAWMPROC ;if zero, go draw it 0SUBQ #1,D0 ;is it choose? 0BNE DoCalcMsg ;if not, go calculate its size ; ; the message was "choose" so examine the mouse position and hilite the appropriate item ; 0MOVE.L MWHICHITEM(A6),A4 ;get pointer to whichItem 0MOVE.W (A4),D3 ;remember oldWhichItem 0CLR (A4) ;set whichItem to zero ; ; if the point isn't in the menuRect, things are easy so test it ; 0CLR.W -(SP) ;make from for PtInRect result 0MOVE.L MPOINT(A6),-(SP) ;push the point 0MOVE.L MMENURECT(A6),-(SP) ;push the rect 0_PtInRect ;test if the point is in the rect 0TST.B (SP)+ ;was it? 0BEQ.S NOITEMSEL ;if not, don't bother checking for the item ; ; the point is in the menu, so waltz through the itemList keeping track of vertical ; position seeing which item its in. In the following loop, D4 holds the item number ; while D2 has the cumulative vertical space ; 0MOVEQ #1,D4 ;start with 1st item 0MOVEQ #20,D2 ;menuBar ends at 19, so start at 20 ; MSELOOP MOVE.L (A3),A0 ;get menuPtr 0MOVE D4,D0 ;get item number 0BSR GETITEMRECORD ;look it up 0BEQ.S NOITEMSEL ;if so, nothing selected ; 0ADD #16,D2 ;bump vertical by itemSize 0TST.B ITEMICON(A1) ;does it have an icon? 0BEQ.S @1 ;skip if it doesn't 0ADD #20,D2 ;icon entries 36 high @1 CMP MPOINT+V(A6),D2 ;compare with mouse point 0BGT.S GOTSEL ;when D2 is bigger, we found it ; ; we didn't reach it yet, so keep stepping down till we do ; NEXTMSEL ADDQ #1,D4 ;bump to next item 0BRA.S MSELOOP ;loop till we find it ; ; we found it so update whichItem. First we better make sure its enabled ; GOTSEL BSR.S ENABLETEST ;make sure whole menu is enabled 0BEQ.S NOITEMSEL ;if not, no selection ; 0MOVE D4,(A4) ; ; see if whichItem changed; if it has, unselect the old item and select the new one ; NOITEMSEL CMP (A4),D3 ;have they changed? 0BEQ.S DONEMPROC ;if not, we're all done ; 0MOVE D3,D0 ;unhilite old item 0BSR.S INVERTITEM ;do it 0MOVE (A4),D0 ;hilite new item 0BSR.S INVERTITEM ;do it ; DONEMPROC MOVEM.L (SP)+,D3-D7/A2-A4 ;restore work registers 0UNLK A6 ;unbuild the stack frame ; 0MOVE.L (SP)+,A0 0ADD #18,SP ;strip parameters 0JMP (A0) ;return to caller ; ; EnableTest is a utility which tests if an item is enabled. It expects a menuHandle ; in A3 and the item number in D4. It returns the result in the Z-flag ; ENABLETEST MOVE.L (A3),A0 ;get menu pointer 0MOVE.L MENUENABLE(A0),D0 ;get enable flags 0BTST D4,D0 ;is item enabled? 0BEQ.S ETDONE ;if not, return 0 0BTST #0,D0 ;test menu bit ETDONE RTS ;return to caller ; ; InvertItem is an internal utility that hilites/unHilites an item. The item number is ; passed in D0. It also assumes A3 has the menuHandle. If the high bit of D0 ; is set, bit-clear with gray instead of inverting the item. ; INVERTITEM MOVEM.L D3-D4,-(SP) ;save work registers 0MOVE D0,D3 ;keep item number in safe place 0BEQ.S INVERTDONE ;if zero, ignore 0MOVEQ #20,D2 ;D2 hold the vertical position 0MOVEQ #1,D4 ;D4 hold item index ; IILOOP MOVE D4,D0 ;get item 0MOVE.L (A3),A0 ;get menuPtr 0BSR GETITEMRECORD ;look it up 0MOVEQ #16,D0 ;its at least 16 long 0TST.B ITEMICON(A1) ;does it have an icon? 0BEQ.S @1 ;skip if it doesn't 0MOVEQ #36,D0 ;icon items are 36 high ; @1 CMP.B D3,D4 ;found the item we want yet? 0BEQ.S GOINVERT ;if so, go invert it 0ADD D0,D2 ;add total to cumulative v position 0ADDQ #1,D4 ;bump to next position 0BRA.S IILOOP ;loop till we find it ; ; its time to invert the item. The menuRect contains the horizontal bounds, D2 contains ; the top of the vertical, D0 has the vertical size ; GOINVERT MOVE.B 1(A0),D1 ;remember 1st char of item 0LEA TEMPRECT,A0 ;get pointer to temporary rectangle 0MOVE.L MMENURECT(A6),A1 ;point to menuRect 0MOVE.L (A1)+,(A0) ;copy menuRect into tempRect 0MOVE.L (A1),4(A0) 0MOVE D2,TOP(A0) ;D2 has the top coordinate 0ADD D0,D2 ;add in the height 0MOVE D2,BOTTOM(A0) ;set up the bottom ; 0TST.W D3 ;invert or bit clear? 0BMI.S GOBITCLEAR ;hi bit set so go bit clear ; 0MOVE.L A0,-(SP) ;push a pointer to the rectangle 0_InverRect ;invert it INVERTDONE MOVEM.L (SP)+,D3-D4 ;recover work regs 0RTS ; GOBITCLEAR CMP.B #$2D,D1 ;is it the dash? 0BEQ.S InvertDone ;if so, don't hilite 0BSR GRAYRECT ;bit clear tempRect with gray 0BRA.S INVERTDONE ;all done! ; ; here is the part of the TextMenuProc that draws the menu. For most of this routine, ; A3 holds the menuHandle, D4 is the item counter and D3 holds the cumulative ; vertical position ; DRAWMPROC MOVEQ #1,D4 ;start with item 1 0MOVEQ #32,D3 ;baseline of 1st item is 12 + 20 0MOVE.L MMENURECT(A6),A0 ;get menuRect pointer 0MOVE.W LEFT(A0),D5 ;get left edge 0MOVE.W RIGHT(A0),D6 ;get right edge, too ; DRAW1MLOOP MOVE D4,D0 ;get item number in D0 0MOVE.L (A3),A0 ;get menu pointer 0BSR GETITEMRECORD ;look it up 0BEQ.S DONEMPROC ;if null item, all done 0MOVE.L A0,A2 ;keep string pointer in A2 0MOVE.L A1,A4 ;keep properties in A4 ; ; draw the mark ; 0TST.B ITEMMARK(A4) ;does it have a mark? 0BEQ.S CHKDRAWICON ;if not, skip ; 0MOVE D5,-(SP) ;push menuRect.left 0ADDQ #2,(SP) ;move in two pixels 0MOVE D3,-(SP) ;push v position 0TST.B ITEMICON(A4) ;does it have an icon 0BEQ.S @1 ;if not, skip 0ADDQ #8,(SP) ;offset checkmark position @1 _MoveTo ;position pen 0CLR D0 ;clear out high part 0MOVE.B ITEMMARK(A4),D0 ;get the mark character 0MOVE.W D0,-(SP) ;push it 0_DrawChar ; ; if its an icon item, bump baseLine by 8 and draw the icon ; CHKDRAWICON MOVE.W #$0100,D0 ;menu icons are 256-511 0MOVE.B ITEMICON(A4),D0 ;does it have an icon? 0BEQ.S DRAWITEXT ;if not, skip ; 0ADDQ #8,D3 ;bump baseLine ; ; draw the icon ; 0LEA TEMPRECT,A0 ;get pointer to rectangle 0MOVE.L A0,-(SP) ;push rect for plotIcon call 0MOVE D3,(A0) ;push top 0SUB #18,(A0)+ ;adjust top 0MOVE D5,(A0) ;push left 0ADD #12,(A0)+ ;dont forget indent 0MOVE.L -4(A0),(A0) ;copy bottom right 0ADD #32,(A0)+ ;bottom := top + 32 0ADD #32,(A0) ;right := left + 32 ; 0CLR.L -(SP) ;make room for function result 0MOVE.L #IconRType,-(SP) ;push the resource type 0MOVE D0,-(SP) ;push icon number 0_GetResource ;get the icon handle 0_PlotIcon ;plot the icon 0ADD #40,D5 ;indent past icon ; ; draw the text of the item ; DRAWITEXT CLR D0 ;clear it out 0MOVE.B ITEMSTYLE(A4),D0 ;push the style parameter 0MOVE.W D0,-(SP) ;push style parameter @1 _TextFace ;get into that face 0CMP.B #$2D,1(A2) ;first char a dash? 0BEQ.S DrawDash ;if so, handle specially 0MOVE D5,-(SP) ;push the x position 0ADD #12,(SP) ;don't forget indent 0MOVE D3,-(SP) ;push y position 0_MoveTo ;position pen 0MOVE.L A2,-(SP) ;push string pointer 0_DrawString ;draw it 0CLR -(SP) ;push empty set 0_TextFace ;restore textface to normal ; ; draw apple character ; 0TST.B ITEMCMD(A4) ;is there one? 0BEQ.S NXTDRAWITEM ;if not, skip @4 MOVE D6,-(SP) ;push right edge 0SUB #24,(SP) ;leave some room 0MOVE.W D3,-(SP) ;push vertical position 0_MoveTo ;position pen 0MOVE.W #APPLEMARK,-(SP) ;push apple character 0_DrawChar ;draw the character 0CLR D0 ;clear high part 0MOVE.B ITEMCMD(A4),D0 ;get command character 0MOVE.W D0,-(SP) ;push command char 0_DrawChar ;draw it 0CLR.W -(SP) ;push normal style 0_TextFace ;restore normal textFace ; ; if the item is disabled, gray it out ; NXTDRAWITEM BSR ENABLETEST ;is it enabled? 0BNE.S NXTDRAW1 ;branch if it is 0MOVE D4,D0 ;get item 0OR #$8000,D0 ;set high bit 0BSR INVERTITEM ;bit clear item with gray ; ; we're done with this item so bump to the next one ; NXTDRAW1 TST.B ITEMICON(A4) ;does it have an icon? 0BEQ.S @1 ;skip if it doesnt 0SUB #40,D5 ;re-adjust D5 0ADD #12,D3 ;bump an extra 12 (36 total) for icon ; @1 ADD #16,D3 ;bump 16 for item 0ADDQ #1,D4 ;bump to next item 0BRA.S DRAW1MLOOP ;loop till done ; handle the case of a dash item by drawing a line DrawDash 0MOVE.L (A5),A0 ;get QuickDraw globals 0PEA Gray(A0) ;set pattern to gray 0_PenPat 0MOVE.W D5,-(SP) ;push x position 0MOVE.W D3,-(SP) ;push y position 0SUBQ #6,(SP) ;center it 0_MoveTo 0MOVE.W D6,-(SP) ;push right edge 0MOVE D3,-(SP) ;push y 0SUBQ #6,(SP) ;center it 0_LineTo ;draw the line 0_PenNormal ;pen back to normal 0BRA.S NxtDraw1 ;dive back into mainstream ; ; GetItemRecord is the main utility used for accessing the menu item data structure. ; It has a register interface to save code. On entry, A0 points to a menuInfo block, ; while D0 has the item number of interest. On exit, A0 points to the item string ; of interest while A1 points to that item's attribute byte list. If the item can't ; be found, A0 and A1 both return NIL. ; GETITEMRECORD TST D0 ;make sure item number is valid 0BLE.S NOITEM ;if its not, don't bother ; 0MOVEQ #0,D1 ;clear D1 for byte arithmetic 0LEA MENUDATA(A0),A1 ;get menuData handle 0MOVE.B (A1)+,D1 ;get title length 0ADD D1,A1 ;skip over title string ; ; here is the item search loop. A1 points to the beginning of the next item. ; GETILOOP SUBQ #1,D0 ;is this the one we're looking for? 0BEQ.S GOTITEM ;if so, we got it 0MOVE.B (A1)+,D1 ;get length of current item 0BEQ.S NOITEM ;length zero marks end of list ; 0ADDQ #4,D1 ;there are 4 bytes of item properties 0ADD D1,A1 ;bump to next item 0BRA.S GETILOOP ;loop till done ; ; the item couldn't be found so return NIL ; NOITEM SUB.L A0,A0 ;zero A0 0MOVE.L A0,A1 ;and A1 too 0MOVE.L A0,D0 ;and set the z-flag 0RTS ;return to caller ; ; we found the item so return a pointer to it in A0 and a pointer to the item properties ; in A1 ; GOTITEM TST.B (A1) ;is this the NIL item? 0BEQ.S NOITEM ;if so, we really didn't get one ; 0MOVE.L A1,A0 ;A0 points to item string 0MOVE.B (A1)+,D1 ;get length 0ADD D1,A1 ;bump to item properties 0RTS ;return to caller ; Calculate the menu size for the given text menu. The handle is in A3. DoCalcMsg 0SUBQ #4,SP 0MOVE.L SP,-(SP) ;point to top of stack 0_GetPort ;get the current port 0MOVE.L WmgrPort,-(SP) ;push the wmgr port 0_SetPort ;set it ; 0MOVEQ #0,D6 ;set initial to 0 0MOVEQ #1,D0 ;find item 1 0MOVE.L (A3),A0 ;point to the menuRecord 0BSR.S GetItemRecord ;point to first item 0MOVE.L A0,A4 ;keep pointer in A4 ; ; here is the main loop of calcMenuSize. Process each item one at a time, keeping the ; height and maximum width in D6 ; CMLOOP 0MOVEQ #0,D7 ;set "extra" width to zero 0MOVE.L (A3),A0 ;handle -> pointer 0MOVEQ #0,D0 ;clear out high part 0MOVE.B (A4),D0 ;get length of item 0BEQ.S CMDONE ;if zero, we're done with this menu 0LEA 1(A4,D0),A1 ;point A1 at the properties ; ; handle the vertical ; 0MOVEQ #16,D0 ;most of the time the item is 16 tall 0TST.B ITEMICON(A1) ;is there an icon for this item? 0BEQ.S @1 ;if not, don't adjust height 0MOVEQ #40,D7 ;add 40 to width for icons 0MOVEQ #36,D0 ;icon entries are 36 tall @1 SWAP D0 ;get vertical into high word 0ADD.L D0,D6 ;increment vertical height ; ; handle the horizontal ; 0TST.B ITEMCMD(A1) ;is there a mark? 0BEQ.S @2 ;if not, skip 0ADD #32,D7 ;add 32 dots extra for commandChar ; @2 0MOVEQ #0,D1 ;clear out high byte 0MOVE.B ITEMSTYLE(A1),D1 ;get style setting @3 MOVE.W D1,-(SP) ;push the style 0_TextFace ;tell LisaGraf about new style 0CLR -(SP) ;make room for stringWidth result 0MOVE.L A4,-(SP) ;move string pointer 0_StringWidth ;find out the width 0ADD.W (SP)+,D7 ;add width to extra 0CMP D7,D6 ;compare with maxWidth 0BGE.S CALCNEXT ;if max is bigger, go process next one 0MOVE D7,D6 ;this one was the biggest ; ; go process next item; loop till we get a null one ; CALCNEXT 0MOVEQ #0,D0 ;zero high part 0MOVE.B (A4),D0 ;get the length of current item 0LEA 5(A4,D0),A4 ;point to the next item 0BRA.S CMLOOP ;loop till done ; ; we've scanned all the items update menuHeight and menuWidth ; CMDONE ADD.W #16,D6 ;leave left and right margin 0MOVE.L (A3),A0 ;get menu pointer 0MOVE.W D6,MENUWIDTH(A0) ;update menu width 0SWAP D6 0MOVE.W D6,MENUHEIGHT(A0) ;update menu height ; 0CLR.W -(SP) ;better restore style to normal 0_TextFace ;set the style 0_SetPort ;restore original grafPort 0BRA DoneMProc ;all done! ; ; GrayRect is a utility that bit-clears the current "tempRect" with gray ; GRAYRECT 0MOVE.L A0,-(SP) 0MOVE.L (A5),A0 ;get QuickDraw globals 0PEA Gray(A0) ;psuh gray 0_PenPat ;set pen to it 0MOVE #PatBIC,-(SP) ;push patBIC penMode 0_PenMode ;set penMode 0_PaintRect ;or on the dim pattern 0_PenNormal 0RTS /.END W^å5P:H r^&47!7!N^; ;File wProcAsm.TEXT ;-------------------------------------------------------------------------- ; ; Window Definition Routine for the ; MacIntosh Window Manager ; ; written by Andy Hertzfeld Aug 4, 1982 ; ; (c) 1982 by Apple Computer, Inc. All rights reserved. ; ; This file contains the window definition procedure ; "DocumentProc", the standard Mac window type. It is ; a rectangular window with a title bar. It is assembled ; part of the window manager. ; ; Modification History: ; ; 21-Aug-82 AJH Made DocumentProc support rectangular windows only ; 30-Aug-82 AJH Added growIcon hit detection, fixed hit to exclude perimeter drag ; 07-Sep-82 AJH Added handler for grow message ; 12-Sep-82 AJH Made it so proc doesn't have to calcRgns when not visible ; 20-Sep-82 AJH Added go-away button drawing and hit-testing ; 25-Sep-82 AJH Added cheap dialogBox window definition proc ; 28-Sep-82 AJH New GoAway button; restructured goAway drawing ; 05-Oct-82 AJH Removed Init message to save code ; 06-Oct-82 AJH Fixed dialogBox dragRgn bug ; 10-Oct-82 AJH Converted to QuickDraw trap interface ; 16-Oct-82 AJH Fixed GoAway hit-test origin bug ; 17-OCt-82 AJH Made both windowProcs preserve A1 ; 07-Nov-82 AJH Changed DocumentProc hiliting to Lisa way ; 14-Nov-82 AJH Improved shape of Grow outline ala Lisa ; 16-Nov-82 AJH Made branch table offset-based to save space ; 16-Nov-82 AJH Special-cased hiliting of small windows ; 20-Dec-82 AJH Changed title bar to 20 pixels tall ; 24-Dec-82 AJH Made wProcAsm a separate assembly ; 17-Mar-83 AJH Added third variant -- shadowless dBoxProc ; 27-Apr-83 AJH only plot, hit-test goAway if window is active ; 25-Jul-83 SC Fixed third variant -- frame was incorrect, see DrawDBox ; 06-Aug-83 AJH changed hiliting to use pattern ; 09-Aug-83 AJH added draw grow icon message receiver ; 20-Aug-83 AJH made it only hit-test or draws goAway if window is active ; 29-Oct-83 AJH new dBox border ; 10-Nov-83 AJH added variant 4 -- just like variant 0, but no inGrow ; 24-Dec-83 AJH fixed structRgn calc bug in variant 1 ; 24-Feb-84 AJH fixed hit-testing of go-away -- was off by 2 ; ;---------------------------------------------------------------------------- 0.INCLUDE TlAsm/SYSEQU.TEXT 0.INCLUDE TlAsm/SYSMACS.TEXT 0.INCLUDE TlAsm/GRAFEQU.TEXT 0.INCLUDE TlAsm/GRAFTYPES.TEXT 0.INCLUDE TlAsm/TOOLEQU.TEXT 0.INCLUDE TlAsm/QuickMacs.TEXT 0.INCLUDE TlAsm/ToolMacs.TEXT ; 0.PROC WDEF,0 ; ; FUNCTION DocumentProc(selector: INTEGER; ; window: WindowPtr, ; message: INTEGER; ; parameter: LongInt): LongInt ; DocumentProc 0BRA.S DP1 ; ; standard header ; 0.WORD 0 ;flags word 0.ASCII 'WDEF' ;resource type 0.WORD 0 ;resource ID 0.WORD 2 ;version number DP1 0LINK A6,#0 ;set up a stack frame to address parameters 0MOVEM.L D3-D6/A1/A3-A4,-(SP) ;save work registers ; ; fetch the parameters into registers ; 0LEA 8(A6),A0 ;get ptr to first parameter 0MOVE.L (A0)+,D3 ;get param in D3 0MOVE.W (A0)+,D0 ;get message 0MOVE.L (A0)+,A3 ;get the window pointer 0MOVE.W (A0)+,D5 ;get the selector integer 0MOVE D5,D6 ;keep copy in D6 0AND #3,D5 ;ignore "inGrow" variant 0CLR.L (A0) ;clear out function result ; ; case out on the message number ; 0ADD D0,D0 ;double for word index 0LEA GoDocProc,A0 ;get jump table address 0ADD.W GODOCPROC(D0),A0 ;compute dispatch address 0JSR (A0) ; ; we're done -- restore registers and return to caller ; 0MOVEM.L (SP)+,D3-D6/A1/A3-A4 ;restore work registers 0UNLK A6 ;unlink stack frame 0MOVE.L (SP)+,A0 ;get return address 0ADD #12,SP ;strip parameters 0JMP (A0) ;return to caller ; ; DocumentProc dispatch table -- entries must be long branches! ; GODOCPROC 0.WORD DrawDoc-GoDocProc ;draw is message 0 0.WORD HitDoc-GoDocProc ;hit test is message 1 0.WORD CalcDoc-GoDocProc ;calc test is message 2 0.WORD DoneDoc-GoDocProc ;it doesn't need init 0.WORD DoneDoc-GoDocProc ;it doesn't need dispose 0.WORD GrowDoc-GoDocProc ;grow message is #5 0.WORD DrawGIcon-GoDocProc ;draw grow icon is #6 ; ; DrawDoc -- draw the document window. The windowPtr is in A3 ; DrawDoc 0TST.B WVISIBLE(A3) ;is it visible? 0BEQ DoneDoc ;if not, don't do anything ; ; see if its a EORGoAway call and special case it ; 0CMP #wInGoAway,D3 ;is it a goAway call? 0BEQ EorGoAway ;if so, go handle it ; 0_PenNormal ;we want the normal pen 0TST.W D5 ;test dialogBox flag 0BNE DrawDBox ;dBox window has no title bar ; ; derive the titleBar rectangle from the structRgn and keep it in TempRect ; 0BSR BuildTBarRect ; ; draw the title bar ; 0PEA TEMPRECT ;tempRect bounds the title bar 0MOVE.L (SP),-(SP) ;make another copy of tempRect pointer 0MOVE.L (SP),-(SP) ;and yet another 0_FrameRect ;frame the title bar 0MOVE.L OneOne,-(SP) ;push inset factor 0_InsetRect 0_EraseRect ;clear the inside ; ; hilite the title bar by filling it with specified pattern ; CheckHilite 0TST.B WHILITED(A3) ;is it hilited? 0BEQ.S DrawTheTitle ;if not, just draw the title 0PEA TEMPRECT ;push the title rect 0MOVE.L (SP),-(SP) ;push a second copy 0MOVE.L #$00030001,-(SP) 0_InsetRect ;inset it some 0MOVE.L (A5),A0 ;get grafGlobals 0MOVE.L TempRect,D0 ;get topLeft 0AND.L #$00070007,D0 ;only use mod 8 0MOVE.L D0,PatAlign(A0) ;get up patAlign 0PEA HilitePattern ;push the pattern address 0_FillRect ;fill the titleBar with the pattern ; 0MOVE.L (A5),A0 0CLR.L PatAlign(A0) DrawTheTitle 0BSR DoTitleString ;draw the centered Title ; ; plot the goAway button, if necessary ; 0TST.B WGoAway(A3) ;is the a goaway button? 0BEQ.S DrawBody ;if not, skip ; 0TST.B WHilited(A3) ;only plot goAway if hilited 0BEQ.S DrawBody ;if not, don't plot goAway 0BSR BuildTBarRect 0LEA GoAwayData,A1 ;get the goAway symbol 0MOVEQ #srcCopy,D1 ;plot in srcCopy mode 0BSR PlotGoAway DrawBody 0MOVE.L OneOne,D4 ;constant for shadowing ; ; frame the body of the window ; DrawFrame 0MOVE.L STRUCTRGN(A3),A0 ;get region handle 0MOVE.L (A0),A0 ;get region ptr 0LEA RGNBBOX(A0),A4 ;point A4 at the bounding box 0SUB D4,Bottom(A4) ;inset the bottom (ignore shadow) 0SUB D4,Right(A4) ;inset the right to ignore shadow 0MOVE.L A4,-(SP) ;push bounding box 0_FrameRect ;frame the body ; ; draw the drop shadow (for variant 0 and 3) ; 0CMP #3,D5 ;variant 3? 0BEQ.S @3 ;if so, paint it 0TST.W D5 ;variant 0? 0BNE.S @1 ;if not, skip @3 0BSR PaintDropShadow ;paint the drop shadow ; ; draw fancy for dialog box ( only for variant 1) ; @1 0CMP #1,D5 ;dialog box? 0BNE.S @2 ;if not, skip 0MOVE.L (A4),TempRect ;copy bounds into tempRect 0MOVE.L 4(A4),TempRect+4 0PEA TempRect 0MOVE.L (SP),-(SP) ;copy it 0MOVE.L (SP),-(SP) 0MOVE.L OneOne,-(SP) 0_InsetRect ;inset it 0MOVE.L #$000A000A,-(SP) ;set pen size 0_PenSize 0MOVE.L (A5),A0 0PEA White(A0) 0_PenPat 0_FrameRect 0MOVE.L (A5),A0 0PEA Black(A0) 0_PenPat 0MOVE.L #$00020002,-(SP) ;push inset factor 0MOVE.L #$00020002,-(SP) ;push new pen size 0_PenSize ;set new pen size 0_InsetRect 0PEA TempRect 0_FrameRect ;and frame it 0_PenNormal @2 ADD D4,Bottom(A4) 0ADD D4,Right(A4) DoneDoc 0RTS HilitePattern 0.WORD $FF00,$FF00,$FF00,$FF00 ; ; BuildTBarRect builds a rectangle enclosing the titleBar in TempRect ; BuildTBarRect 0LEA TEMPRECT,A0 ;get pointer to tempRect 0MOVE.L STRUCTRGN(A3),A1 ;get structure region handle 0MOVE.L (A1),A1 ;get strucRgn pointer 0ADDQ #RGNBBOX,A1 ;point A1 at the bounding box 0MOVE.L (A1)+,(A0) ;copy bounding box into tempRect 0MOVE.L (A1),4(A0) ; ; make bottom := top + 19 ; 0MOVE Top(A0),D0 ;get top 0ADD #19,D0 ;compute top+19 0MOVE D0,Bottom(A0) ;update bottom 0SUBQ #1,Right(A0) ;inset right 0RTS ;return to caller ; ; EORGoAway hilites/unhilites the goAway button. It falls through into PlotGoAway ; EorGoAway 0BSR.S BuildTBarRect ;build the bounding rect 0LEA GoAwayData,A1 ;get the bitMap 0ADD.W #32,A1 ;bump to the EOR Mask 0MOVEQ #2,D1 ;set EOR as the plot mode ; ; PlotGoAway plots the goAway button. A1 holds the symbol, D1 the plotting mode ; PlotGoAway 0LEA TempRect,A0 ;get pointer to tempRect 0MOVE Left(A0),D0 ;get left edge 0ADDQ #7,D0 ;leave some margin 0MOVE D0,Left(A0) ;update left 0ADD #16,D0 0MOVE D0,Right(A0) ;update right ; 0MOVE D1,D0 ;set plotting mode 0ADDQ #2,TempRect+Top 0SUBQ #1,TempRect+Bottom 0MOVE.L #$00100010,D1 0BSR PlotSymbol ;plot it in tempRect 0BSR.S BuildTBarRect ;rebuild tempRect 0RTS ; ; DialogBoxes have no title bar and extra shadow ; DrawDBox 0MOVE.L #$00020002,D4 ;get shadow factor 0CMP.W #3,D5 ;does it have shadow? 0BEQ.S DrawFrame ;if so, we're cool 0MOVEQ #0,D4 ;otherwise no shadow 0BRA.S DrawFrame ;go draw it ; ; DoTitleString is the common code that draws the title centered in tempRect. Warning -- ; it trashes D3. ; DoTitleString 0BSR BuildTBarRect ;calculate title bar rect ; ; compute indent factor based on GoAwayButton state ; @1 MOVE.W TempRect+Right,D3 ;get right 0SUB.W TempRect+Left,D3 ;compute width ; 0SUB.W WTITLEWIDTH(A3),D3 ;compute extra x 0ASR.W #1,D3 ;divide by 2 ; ; if there's a goAway button, make sure the margin is at least 32pixels ; 0TST.B WGoAway(A3) ;is there a go away button 0BEQ.S @2 ;skip if there's not 0TST D3 ;is it negative? 0BMI.S @3 ;if so, pin at 32 0CMP.W #32,D3 ;if goAway button, must have some margin 0BGT.S @2 @3 MOVEQ #32,D3 ; @2 ADD TempRect+Left,D3 ;compute x position 0MOVE.W D3,-(SP) ;and push for MoveTo ; 0MOVE TempRect+Bottom,-(SP) ;push bottom 0SUBQ #5,(SP) ;leave room for descenders 0_MoveTo ; clear it out if it was hilited 0TST.B WHilited(A3) ;was it hilited? 0BEQ.S @4 ;if not, skip 0SUBQ #6,D3 ;indent to the left 0MOVE D3,TempRect+Left 0ADD.W WTitleWidth(A3),D3 ;add in the length 0ADD #12,D3 ;indent on right 0MOVE D3,TempRect+Right 0SUBQ #2,TempRect+Bottom ;protect bottom line (in business) 0PEA TempRect 0_EraseRect ;erase it ; ; draw the string ; @4 0MOVE.L WTITLEHANDLE(A3),A0 ;get titleHandle 0MOVE.L (A0),-(SP) ;push title pointer 0_DrawString ;draw it ; DoneDString 0RTS ;all done drawing title... ; ; BitMap for default GoAway button ; GoAwayData 0.WORD $0000,$0000,$BFFB,$2008 0.WORD $A00B,$2008,$A00B,$2008 0.WORD $A00B,$2008,$A00B,$2008 0.WORD $BFFB,$0000,$0000,$0000 ; Mask for goAway button ; 0;.WORD $0000,$0000,$FFF4,$4110 0;.WORD $C934,$4550,$C014,$5C60 0;.WORD $C014,$4550,$C934,$4110 0;.WORD $FFF4,$0000,$0000,$0000 ; .WORD $0000,$0000,$0000,$0118 ; .WORD $093C,$0558,$001C,$1C68 ; .WORD $001C,$0558,$093C,$0118 ; .WORD $0000,$0000,$0000,$0000 0.WORD $0000,$0000,$0000,$0100 0.WORD $0920,$0540,$0000,$1C70 0.WORD $0000,$0540,$0920,$0100 0.WORD $0000,$0000,$0000,$0000 ; ; ; HitDoc -- perform a hit test on the document. On entry, D3 contains the mousePoint ; in global coordinates while A3 holds the window pointer ; HitDoc 0MOVEQ #16,D4 ;keep 16 in a register to save code 0CLR.W -(SP) ;make room for function result 0MOVE.L D3,-(SP) ;push the mouse point 0MOVE.L CONTRGN(A3),-(SP) ;push content region handle 0_PtInRgn ;is the point in the content region? 0TST.B (SP)+ ;well, is it? 0BEQ.S NotInContent ;if not, go check out drag region ; ; its in the content region -- see if its in the grow icon area ; 0TST.W D5 ;is it a dialogBox? 0BNE.S justContent ;if so, its only in the content 0SUBQ #3,D6 ;inGrow enabled? 0BGT.S justContent ;if not, skip 0TST.B WHilited(A3) ;is it active? 0BEQ.S justContent ;if not, it cant be in grow ; 0MOVE.L ContRgn(A3),A0 ;get region handle 0MOVE.L (A0),A0 ;get region ptr 0MOVE.L RgnBBox+botRight(A0),D0 ;get bottom left of content ; ; first consider the x coordinate ; 0SUB D4,D0 ;offset x by 16 0CMP D0,D3 ;if <, just in content 0BLT.S justContent ; ; its within range on x so try y ; 0SWAP D0 0SUB D4,D0 ;check out y dimension 0SWAP D3 0CMP D0,D3 ;compare y coordinates 0BLT.S justContent ; 0MOVEQ #wInGrow,D0 ;flag in grow Icon 0BRA.S DoneHitDoc ; ; the point is in the content region so return a '1' ; justContent 0MOVEQ #wInContent,D0 ;return in content 0BRA.S DoneHitDoc ;go store function result and return ; ; its not in the content -- see if its in the dragRgn (content extended by titleBar) ; NotInContent ; 0TST D5 ;is it a dialogBox? 0BNE.S DoneHit1 ;dBoxes have no drag region ; 0CLR.W -(SP) ;make room for function result 0MOVE.L D3,-(SP) ;push the mouse point 0MOVE.L ContRgn(A3),A4 ;get content region handle 0MOVE.L (A4),A4 ;get region ptr 0ADDQ #RgnBBox,A4 ;get bounding box ptr 0SUB #19,Top(A4) ;make it 19 higher 0MOVE.L A4,-(SP) ;push the rect 0_PtInRect ;is the point in the title bar? 0ADD #19,Top(A4) ;fix up content bounds ; 0TST.B (SP)+ ;examine result 0BEQ.S DoneHit1 ;if not, return 0 (do nothing) ; ; see if its in leftmost 16 of drag, which is the goAway button ; 0TST.B WHilited(A3) ;is it hilited? 0BEQ.S ItsInDrag ;if not, can't be in GoAway 0TST.B WGoAway(A3) ;is there a goAway button? 0BEQ.S ItsInDrag ;if not, skip 0MOVE D3,D0 ;get mousePt 0ADD PortBounds+Left(A3),D0 ;convert to local 0SUB PortRect+Left(A3),D0 ;compensate for origin 0CMP #18,D0 ;is it too far right? 0BGT.S ItsInDrag ;if so, its in drag 0SUBQ #8,D0 ;it must be at least 6 0BMI.S ItsInDrag ; ; its in the goAway button so signal it ; 0MOVEQ #wInGoAway,D0 0BRA.S DoneHitDoc ; ItsInDrag 0MOVEQ #wInDrag,D0 ;flag in drag region DoneHitDoc 0MOVE.L D0,20(A6) ;update function result DoneHit1 RTS ; ; CalcDoc -- calculate the structure and content regions for the window pointed ; to by A3. ; CalcDoc 0LEA TEMPRECT,A0 ;get a pointer to the work rectangle 0MOVE.L A0,-(SP) ;push for later offset 0MOVE.L PORTRECT(A3),(A0)+ ;copy topLeft of portRect 0MOVE.L PORTRECT+4(A3),(A0) ;copy botLeft of portRect ; ; offset it to global coordinates ; 0MOVE.L PORTBOUNDS(A3),-(SP) ;push topLeft of port.portBits.bounds 0NEG 0(SP) ;negate offset 0NEG 2(SP) ;both words 0_OffsetRect ;offset tempRect to global coordinates ; ; make the rectangular content region ; 0MOVE.L CONTRGN(A3),-(SP) ;content region gets the esult 0PEA TempRect ;tempRect is the rectangle 0_RectRgn ;go make the region into content region ; ; now do the structure region. First correct the bounding rectangle (tempRect) for ; structure instead of content ; 0MOVE.L #$00020002,D4 ;get the shadow factor for DBox 0MOVE.L STRUCTRGN(A3),-(SP) ;push the structRgn for later 0PEA TEMPRECT ;push a pointer to the rect 0MOVE.L (SP),-(SP) ;make two copies 0MOVE.L MinusOne,-(SP) ;make 1 pixel bigger, all around 0_InsetRect ;make it bigger 0TST.W D5 ;is it dBox? 0BNE.S DoDBoxCalc ;skip if it is 0SUB #18,TempRect+Top ;make top 18 pixels higher 0LSR.L #1,D4 ;adjust shadow factor CalcCommon 0_RectRgn ;RectRgn(structRgn,tempRect) ; ; now add in the 1 or 2 pixel drop shadow (if necessary) ; 0TST D5 0BEQ.S @1 ;if so, it has shadow 0CMP #3,D5 ;is it variant 3? 0BNE.S NoDropShadow ;if not, no shadow @1 0CLR.L -(SP) ;make space for result 0_NewRgn ;allocate new region 0MOVE.L (SP),A4 ;remember it 0PEA TempRect ;push tempRect 0MOVE.L (SP),-(SP) ;save another copy 0MOVE.L D4,-(SP) ;push shadow factor 0_OffsetRect ;offset it 0_RectRgn ; 0MOVE.L StructRgn(A3),-(SP) 0MOVE.L A4,-(SP) ;offset region 0MOVE.L StructRgn(A3),-(SP) ;structure gets the result 0_UnionRgn ;add it in ; 0MOVE.L A4,-(SP) ;we're done with it so 0_DisposRgn ;dispose of it ; ; all done with CalcDocRgns ; NoDropShadow 0RTS DoDBoxCalc 0CMP #1,D5 ;is it variant 1? 0BNE.S CalcCommon 0PEA TempRect ;push our rectangle 0MOVE.L #$FFF9FFF9,-(SP) ;push (-7,-7) 0_InsetRect ;inset it 0BRA.S CalcCommon ;use common code for the rest ; ; GrowDoc handles the grow message by drawing a grow outline based on the rectangle ; passed in D3 ; GrowDoc ; ; first make it one pixel bigger to jibe with the structure ; 0MOVE.L D3,-(SP) ;push the rect 0MOVE.L MinusOne,-(SP) ;push (-1,-1) 0_InsetRect 0MOVE.L D3,A0 ;get rect ptr 0SUB #18,Top(A0) ;make it higher ; 0MOVE.L D3,-(SP) ;push the rectangle 0_FrameRect ;frame it 0MOVE.L D3,A3 ;keep rectangle pointer in A-reg ; ; now that the rectangle is drawn, draw the lower horizontal line ; 0MOVE.W Left(A3),-(SP) ;push left 0MOVE.W (SP),-(SP) ;save for upper line 0MOVE.W Bottom(A3),-(SP) ;push bottom 0SUB #16,(SP) ;really 16 pixels above bottom 0MOVE.L (SP),-(SP) ;make a copy of this point 0_MoveTo ;move to it 0MOVE.W Right(A3),2(SP) ;now go to the right edge 0_LineTo ;draw the horizontal line ; ; draw the upper horizontal line ; 0MOVE.W Top(A3),-(SP) ;push top 0ADD #18,(SP) ;really 18 pixels below top 0MOVE.L (SP),-(SP) ;make a copy of this point 0_MoveTo ;move to it 0MOVE.W Right(A3),2(SP) ;now go to the right edge 0_LineTo ;draw the horizontal line ; ; draw the vertical line ; 0MOVE.W Right(A3),-(SP) ;push right 0SUB #16,(SP) ;really want right - 16 0MOVE.W Top(A3),-(SP) ;push top 0ADD #18,(SP) ;really want top + 18 0MOVE.L (SP),-(SP) ;make a copy of this point 0_MoveTo ;and move to it 0MOVE.W Bottom(A3),(SP) ;now go to bottom edge 0_LineTo ;draw the vertical line ; ; restore the rect back to how it was when we got it ; 0MOVE.L D3,-(SP) ;push the rect 0MOVE.L OneOne,-(SP) ;push (1,1) 0_InsetRect 0MOVE.L D3,A0 ;get it in an A-reg 0ADD #18,Top(A0) ;fix up the top ; 0RTS ;all done! ; ; Utility PaintDropShadow -- drop shadows the rectangle in A4, by the amount in D4 ; PaintDropShadow 0MOVE.L D4,-(SP) ;push shadow factor 0_PenSize ;make penSize = shadow factor ; 0MOVE RIGHT(A4),D0 ;get right of menuRect 0MOVE D0,-(SP) ;push right 0MOVE TOP(A4),-(SP) ;push top 0ADD D4,(SP) ;want top+shadow 0MOVE D0,-(SP) ;push right 0MOVE BOTTOM(A4),D0 ;get bottom 0MOVE D0,-(SP) ;push bottom 0MOVE LEFT(A4),-(SP) ;push left 0ADD D4,(SP) ;want left+shadow 0MOVE D0,-(SP) ;push bottom ; 0_MoveTo ;MoveTo(left+shadow,bottom) 0_LineTo ;LineTo(right,bottom) 0_LineTo ;LineTo(right,top+shadow) ; 0_PenNormal ;restore normal pen 0RTS ; ; PlotSymbol -- plot the little 16 by 16 symbol bitmap pointed to by A1 into the rectangle ; pointed held in TempRect. D0 holds the mode. ; PlotSymbol 0LEA IconBitMap,A0 ;get pointer to source bitmap 0MOVE.L A1,(A0)+ ;update base address of bitMap 0MOVE #2,(A0)+ ;update rowBytes 0CLR.L (A0)+ ;topLeft is zero, zero 0MOVE.L D1,(A0) ;adjust boundsRect ; ; push parameters for CopyBits call to transfer arrow bitMap ; 0PEA IconBitMap ;push pointer source bitmap 0MOVE.L (SP),A0 ;remember in A0, too 0MOVE.L LGLOBALS(A5),A1 ;get lisaGraf global baseaddress 0MOVE.L THEPORT(A1),A1 ;get thePort 0PEA PORTBITS(A1) ;that's the destination bitmap ; 0PEA BOUNDS(A0) ;boundsRect of bitmap is source 0PEA TempRect ;tempRect is the destination 0MOVE.W D0,-(SP) ;theMode is in D0 0CLR.L -(SP) ;no mask region ; ; transfer the bitMap (stretching as necessary...) ; 0_CopyBits ;let Bill stretch those bits 0RTS ;return to caller ; Draw the grow icon. First make this window the current grafPort DrawGIcon 0MOVE.L A3,-(SP) ;push it 0_SetPort ;make that the port ; ; compute the grow icon rectangle in tempRect ; 0LEA TempRect,A4 ;get pointer to tempRect 0MOVE.L PortRect+4(A3),4(A4) ;copy in botRight of tempRect 0MOVE.L 4(A4),(A4) ;into the topLeft, too 0SUB.W #15, Top(A4) ;subtract from Top 0SUB.W #15,Left(A4) ;and left, too ; ; plot the grow icon ; 0TST.B WHilited(A3) ;is it hilited? 0BEQ.S ClearGoAway ;if not, go clear it 0LEA GrowBits,A1 ;get pointer to the bits 0MOVEQ #0,D0 ;use srcCopy 0MOVE.L #$00100010,D1 0BSR PlotSymbol ;plot it ; ; plot the boundary lines ; PlotBoundary 0MOVE.W Left(A4),-(SP) ;push tempRect.left 0MOVE.W (SP),-(SP) ;copy it again for later 0MOVE PortRect+Top(A3),-(SP) ;push portRect.top 0_MoveTo ;move to it 0MOVE PortRect+Bottom(A3),-(SP) ;push portRect.bottom 0_LineTo ;draw the vertical line ; ; now draw the horizontal line ; 0MOVE.W PortRect+Left(A3),-(SP) ;push portRect.left 0MOVE.W Top(A4),-(SP) ;push tempRect.top 0_MoveTo 0MOVE.W PortRect+right(A3),-(SP) ;push portRect.right 0MOVE.W Top(A4),-(SP) ;push tempRect.top 0_LineTo ; ; all done with DrawDocGrow ; DoneDDG 0RTS ClearGoAway 0PEA TempRect 0_EraseRect 0BRA.S PlotBoundary ; ; BitMap for GrowIcon ; GrowBits 0.WORD $0000,$0000,$0000,$1FE0 0.WORD $1020,$103E,$1022,$1022 0.WORD $1022,$1022,$1FE2,$0402 0.WORD $0402,$0402,$07FE,$0000 0;.WORD $0000,$0000,$3E00,$2200 0;.WORD $2FC0,$2840,$3840,$09FC 0;.WORD $0904,$0F04,$0104,$0104 0;.WORD $0104,$01FC,$0000,$0000 ; 0.END RAMBOOT RAMBOOT RAMBOOT LK`System Finder Macsbug Disassembler StartUpScreen Finder Clipboard File C"8HA An,rPBJgpH@ѸѸ$ѸfѸ r x Aor/pA BQ4:p"CTSB2BBBa#FXUAf3 _W!YO/ _W!YO/abf BgB/ Op)ɩXO`a y@NО2 O1|1|1x2Nu~`JGgNu `apd`pBQ/K O PJ@Nuv2 OtE$BB$f,f&(|FJCk.f""x $$XJ4$ft02Nu2|`؆|` "H O`/<VB/<`@BgKEr/HRHoHjBgBNuDhPASLIB STDUNIT XBLKIOINTfBLOCKIO gPASHEAP h`4T( W$X&N$V~N&NN&"X/Nњ<PASLIB1 PASIOLIB`SULib cMainProg TW$JoNVH n CJp"S@n2 nCJp"S@n2AxCp S@n0HnvHnx"JnvnfA/HzHn",>JGf8HmH?<(p(mHA/A"Lp"S@n29|"B$`Hn?< S@?HnL"ACLp S@n0HnvHnHnx"JnvnjHnx.x@Y@??<Hn*"Hn*Hz:"g NumFreeABlocks Deleted data fork for file Deleted resource fork for file JoNVH&nJHV/Bg  g+g8/- HzBg/- mH/Bg/- HzBgBgh_`|+g mH-H m"n0)"Ac2IJlgA2?<"z/?,BgNJl gA2?<"z/?, <NBlBBBl B"B&B0-S@;@ mH+h$H`LN^.NuROCESSN ? Delete JoNV/ (nA/BgA?<"z/Ng n,HN8B,HzDHl",J_o$|Hz.Hl",0AA=`(_N^.NuILDCRDS?JoNVHB"-_ nCJp@"S@npA0A AA?<"z/Nf`HnBg(`>/NBgA?<"z/Nxg/N|`/- Hz2Bg/-  O ./"LN^.NuELETEMANo such files?JoNV0-X@2.UA@=A N^ _TONISKADD JoNVAC 0HnHn"`Jn^ n&V nfV nlVg?.HzBgN, nfg>| ACd 0HnHn֠"Jn^ nfVg?.HzBgN,N^NuJECTSONP#Calling fs_utilities from EjectSonylowerCalling UnMount from EjectSonyLOWERJoNV/=| HmB@=@pAng/-:g nB`* n0 ~ nO /- .?<pAng/-: gHmB@=@/-: g/- .?<pAng4RGp n//.HnHn?<" _Cp@ S@n`8/- < ?</- .?< Go/.??<"SG`B/-:g/-/-  .N^.NuSREADLNJoNV/ nCJp@"S@nHnHzB"  gpA0ApAAWDG .N^.NuSCAPE JoNVHn"HmBg(N nl0|Bn=mHnHn֠"Jno?.HzBgN*"N^NuINISHMA&$Calling fs_utilities from FinishMainJoNV n JPn n 0N^ _\ONIRSTERRJoNV/=| 0-R@=@>.`Bg?N J_f=G `4RGino0.S@=@~`Bg?N xJ_f=G ` RGino.N^ _TONREEBLOCJoNVH0-HЮS/0-H/" =@|xgTBg?NL>GlB|0.S@=@BE`Bg E?NJ_gB.REino.g=G `<`B`Bg?<N=_ LN^.NuREERUN JoNV n CJp"S@n2|=|A-H nCp S@n0BHnHn"J]Jn^g n0B.` n0|N^ _PONETDEVICJoNVH nCJp"S@n2HnHzn"gLHz^Hnޠ",>JGfACp S@n0`(Hn?< S@?Hnl"AClp S@n0(mH0.n < gJGfA/HmPHnJ.f|SHnHz" .W@gd/- HzBg/- HzrBg/- HzpBgHmTNHmTHzX"gATC> 0`BgAT?<"z/Ng`|AC 0HnHnʠ"Jno?.HzBgN!\`\;|;|;| ;|;|BN b+_BN X+_BmBm;|-Sg=mP`=m=| 0.U@U@nHH@J@=@Jng20.n/- HzBg/- 0.H/?</-  ;n0.U@U@nH;@0-H+@0-H+@0.X@;@p+@0-S@;@ACTp S@nBn`0.AAB0Rn no0-T@S@??<Nt/- Hz:Bg/-  |BmO ./"LN^NuNITDISK$Disk sucessfully initialized.-Warning: rounding up # of directory blocks toformatting Mac diskLOWERMac.Boot] 'Name of file to get boot blocks from? [ blocks]Size of Mac Directory? [ MacComDiskName of Mac volume? [? Trash current Mac volume: Starting to initialize a disk.JoVNVV/Hm?JGl D@|>/- O?<RF Fo/-  mH+h$H`/-  /- HzzBg/- 0-H/?</- Hz= 0BCurrent MacCom restriction, too many Entries in this Mac Directory reading Mac directoryReading directory on Mac disk: JoNV/ n CJp@"S@n(n?.HnHzdHlHn?<"A?<"z/BgNg HlB?,>"8 nB( n,HNl(_N^ _ NEAVE  on JoNV/ (nR9_BJlBo?,BHz&BgN n,HN(_N^.NuHECK Writing '.MFEN' fileJo\NVXHB"-_X nCJp@"S@n nCJp@"S@n n CJpL"S@n2|Bn>HnBHnBg"FJnBoB nzBf,BgA?<"z/N߲ g BgHz4/Nr`?.BHz/NbHnBHnHn>?:"|JnBo?.BHz/N: ngHnBA8/?-Bg?.N:N JnBo?.BHz/NHnB?.>A8/0-H/Hn:<B"lJnBo?.BHzT/N0-H:g?."8JnBo?.BHz/N|HnBHnHn>?:ڠ"|JnBo?.BHz/NTHnB?.>Hn\"JnBo?.BHz/N0 .м-@ .м-@HnB?.>Hn\"JnBo?.BHz0/NHnB?.>"8JnBo?.BHz/N/- HnBg/- < .@r@?/- HzBg/- HnBg/-  HnDHnHz~Hn\?<"Hn\?<2/NHnD _CpL S@n0HnD/NHnD?<(/NO@ .X/"LN^ _NFERFILE.MFEN copied to Lisa file: calling CLOSE_OBJECTcalling P_Set_File_Info calling Info calling OPENactual <> allocSize calling WRITE_DATA calling UReadcalling MAKE_FILETransfer AbortedJoNVH&nJHV/Bg  g+g6/- Hz2Bg/- mH/Bg/- HzBgBgh`~g(mHACp@ S@nJkzg(/ Hn?+z"Hn@kz??<"`^JkxVJkvVgNA"Lp S@n0Hn?<0+vS@?"HnHn?+x"Hn.@kx??<"Hk~HnHn?<"ACp@ S@n~ m0,"Ac2JpgNBg?<"z/ A?<"z/ m0,"Ac2?0 m0,"Ac2Hp/N m0,"Ac2Jp VgbBg?<"z/ HnHzpHn?<"A?<"z/ m0,"Ac2?0 m0,"Ac2Hp/N mH+h$H`LN^.NuROCESSN8.RSRC+? (Apple Period followed by 'N' to escape) Copy JoNVH(nA/HzHl",>JGgVHl R@?,@G?Hn"ACp@ S@nHl?< S@?Hn"ACp@ S@n`/- HzBgHlNvHlHz~"g$pA0A A-fHl?<?<"HzLHl",<JFohHz:Hl?<?Hn"HnHn?<"A~Cp S@n0Hl R@?,@F?Hn"ACp@ S@n`B,~BgA?<"z/NBgA?<"z/Ng n,HNB,HzHl",J_o$|HztHl",0AA=`HzTHl",9_zBlx9|vJlzf Hz2Hl",9_xHz"Hl",9_vLN^.NuILDCRDS&=$?-Copy to what Lisa file? ,JovNVrHB"-_r nCJp@"S@npA0A A/NBgA?<"z/Ng/N`/- Hz2Bg/-  OZ .r/"LN^.NuEADMACFNo such files?JoNVBgA r@Ё/0.U@?N)x=_ N^ _TONEADMAP JoNVHnA/0<@??<NJn_ mWD@;m;m0-H;@;mN^NuEADMASTJoNV/ n CJpL"S@n2(n(. H2AC@.@g|`B,9n)n(_N^ _ NETTAG JoNV/BBgNgBgN0  g/- Hz$Bg/-  G.N^NuTARTCONBAI'm having trouble reading the directory on this disk, try again.JoNVN/- Hz$Bg/-N'>N^NuTARTOVE0.Command aborted. Press Return to start over. JoNV=n N^ _TONONYADD JoNVH0. |H< nBP=F~`Bg?.N:Hn?-/. p/H/Hn<Bg"NJno\ nffN/- HzBg/-``*/- Hz`Bg/- 0.H/?</-  /.?.N, RnRGinoZLN^ _ NREAD ZUnit read errorINo disk in the drive! Insert the disk, type 'Ready', then press Return: JoNVH nCJ"""0.|H< nBP=F~`Bg?. NV:Hn?-/.p/H/Hn<<"NJno\ nffNr/- HzBg/-``*/- Hz`Bg/- 0.H/?</-  /.?.NRn RGinoXLN^ _NWRITE \Unit write errorINo disk in the drive! Insert the disk, type 'Ready', then press Return: JoNV/- HzbBg/-  HnHmT?<R=_JnoBg/- 0-nmH/?</-  LN^NuRITEDIRCSerious!!..inconsistent directory, nextFreeEntry - master.nFiles = TSerious problem..file Directory too small. Init disk with a larger directory size!!6writing directory. Your disk may now be inconsistant!Writing File DirectoryJoNV n CJp@"S@nNF/-  /- HzBg/- 0.H/?</- HzfBg/- HnBg/-  /- Hz,Bg/-.gNN^ _PONRITEERR(Please press Return: , Error number JoNVH&nACp@ S@nA/0-S@=@BG` mOc 2IArC2p@ S@nAr/HnHkr"g|w7Gt+ gPJl g6BgA2?<"z/N8gA2?<"z/?, <N9k )k")k&`LJlg4BgA2?<"z/NgA2?<"z/?,BgN̐9k)k)kRGino LN^.NuHECKFORJo.NV.H&nHntHkHzHn.?<"Hn.?<2RJ_^D@s+s gHnt _C~pL"S@n2I~+sg`JmH|2ACB,+sgBG` OB4pRG Go)m+ gXBg/+N9_ 7l z+sg)k"0-HЫS/0-H/"0-H/")_&BlBB`VBg/+NӘ9_7lz+sg)k0-HЫS/0-H/"0-H/")_Bl B"B&A2Cp@ S@nB+w+s g HntBg(LN^.NuETUPFIN.MFENJoNVH nCJp@"S@n(n&l-gF/- HnBg/-Hl?</-,@J@W,A AWg`B,A/HlHz"g ACn 0=n>.`>0. GAA0A0@A m0+tAc2OGRGinoLN^ _NETINFO ????JoNVH n CJp@"S@n&n(k(l?.A?<"z/BgN kg ?+?<NDHlBg( nB( n,HNJLN^ _ NEAVE JoNVHB"-_ nCJp@"S@n|=| n hHhHn?<R=_Jno.?.Hz:HnHn?<"A?<"z//N n h(s n h(wg m"n"i0)tAc2A-HHnHnHn"(Jno?.Hz/N n h(sg .R n!@* .Z n!@. n+h.=n =|`~=mBn`0.AAB0Rni 0.no n hHhHn0-H??<=_R=_Jno.?.HzHnHn?<"A?<"z//N n h h hHh m"n"i0)tAc2Hp n h( H2AC0.S@?NBHnA/?-Bg?.N n h h hHhNJno6?.Hz n hHhHn?<"A?<"z//N=nBg0.R@?N\=_?.?.NdRni 0.noz?.?<NF n hHhBg(/- HnBg/- < .@r@?/- HzLBg/- n hHhBg/-  O ./"LN^ _NRITEFILP copied to writing to reading from calling LookUp to set the datesopening JoNV/ (n0-lS@H9@|0,|mm8BgHzHlHn?<"A?<"z/BgN n,HN,w gl m0-Ac2AC~pL S@n09mtRm mco$BgHzBgNfSm n h h,HN0-R@;@ -R+@,w ,s-g`HzBg?<?</NHzZ?<?<? NumFreeABlocks No space left on diskSet the Bundle Bit? Creator? [????] Type? [????] BCurrent MacCom restriction, too many Entries in this Mac Directory!Not enough space on disk to copy JopNVlHB"-_l nCJp@"S@n nCJp@"S@n-gDHzzHn",=_pJnpV.AnpVgHn?<?.p"`BnpJnpf/N/Nh/NOT .l/"LN^ _NONFILE /JoNVH(nJHV/Bg  g,@Y@GWJGVgHl,@Y@??<"|A?<"z/A?<"z//, ,м//<" ?,/NB,`?,Hz*BgN mH+h$H`LN^.NuROCESSNVWriteMacFiles, Calling LookUp.RSRC+? (Apple Period followed by 'N' to escape) Copy JoNVH(nA/HzHl",>JGgVHl R@?,@G?Hn"ACp@ S@nHl?< S@?Hn"ACp@ S@n`/- HzBgHlNB,HztHl",J_o$|Hz^Hl",0AA=`pA0A A-fHl?<?<"HzHl",9_JlolHzHl?<?,Hn"HnHn?<"ACp@ S@nHl0,R@?,@l?Hn"ACp@ S@n`B,BgA?<"z/N8BgA?<"z/N"g n,HNrHzTHl ",9_Bl9|Jlf Hz2Hl ",9_Hz"Hl",9_LN^.NuILDCRDS"=$-?Copy to what Mac file? ,JoNVHB"-_ nCJp@"S@npA0A A writing master directory. Your disk may now be inconsistant!Writing Block MapJoNV/- Hz Bg/-  N^.NuEBUGSTU86This version of MacCom does not include debugging codeJoNV/ (n/- HzfBgHlN:BgA?<"z/N g&BgNngA?<"z/NNN(_N^.NuELMACFIMac files to Delete? JoNV/- Hz Bg/-  N^.NuUMPBLOC86This version of MacCom does not include debugging codeJoNV/-  /- HzvBg/-  /- HzBBg/-  /- HzBg/-  /- HzBg/-  /- HzBg/-  /- HzFBg/-  /- HzBg/-  /- HzBg/-  /- HzZBg/-  /- Hz Bg/-  /- HzBg/-  /- Hz`Bg/-  /-  /-  /- HzBg/-  /- HzBg/-  /- HzLBg/-  /- Hz Bg/-  N^.NuELP $ as a resource file.> can recurse. A '.RSRC' suffix means this file will be output@ characters. A '<' prefix gets command input from a file. This> Files are specified with the usual '?', '=', pattern matching0'X' allows you to display debugging information.K'R' remove = TRUE, in Lisa->Mac, removes parts of file names preceding '/'.8'P' paranoid = TRUE, asks you before deleting old files.D'F' finderinfo = TRUE allows you to enter your own finder info data.;'B' allows you to write just the boot blocks on a Mac disk.&'Names' lists the names on a Mac disk.3'Mac->Lisa' sends files from your Mac to your Lisa.3'Lisa->Mac' sends files from your Lisa to your Mac. 'Init' initializes the Mac disk. You are using Help now!'Eject' ejects the Mac disk.''Delete' deletes files from a Mac disk.JoNVBgNHg N2NNN^.NuNITTHEDJoNV/ (n/- HzfBgHlNbBgA?<"z/N g&BgNݖgA?<"z/NNN(_N^.NuISATOMA"!Lisa files to write to Mac disk? JoNVATC: 0B-SATC N@N^.NuOCALINI MacComDiskMac.BootJoNV/ (n/- Hz^BgHlNtBgA?<"z/N gBgNܨgA?<"z/Nf(_N^.NuACTOLIS$#Mac files to write to Lisa volume? JoNV/ (nBgBg"Nr/- HzZBg/-B@9@Bg?,9_N$BgBg"/- Hz"Bg/-  (_N^.NuROMPT POMacCom: Delete, Eject, Help, Init, Lisa->Mac, Mac->Lisa, Names, B,F,P,R, Quit: JoNV/- HzBg/- HznBg/- HzlBgHmTNHmTHzT"gATC: 0`BgAT?<"z/N.g`NN^.NuRTBOOTB8Mac.Boot] 'Name of file to get boot blocks from? [JoNVN?<?<"/- Hz Bg?<?<"/- Hz&Bg?<?<"/- HzBg/N./N0.@Bk @nH0;N0:DLhpx/N`/NX`N`/- HzBgBgBg8_`~/N `v/N`n/N`f/N`^BgNپgHzN*`J/- HzBgBgBg8_!`./- Hz@BgBgBg8_`/NN` ``/NL nQfN^NuAINPROG8In Lisa->Mac, remove parts of file names preceding '/'? 3Always double check before overwriting a Mac file? =7Always set the finder info when writing to a Mac file? 5*****************************************************5* MacCom (May 14, 84) *"NV,_NU"+O+NB"+_N@.m,m -/"N,.m,m -/"NV"N]"NuN^NuACCOM H06/ $<2< 0/He0@VH2< QL _PNH00/ HU0@2<QJf?@L _\N _""_$_Sf$@NЁWMainProgHardware&NVCopyright 1983, Apple Computer Inc. /BGNE.Nu o/><hNE. _XON o/><jNE. _XON _/><lNE.N/><NE.Nu/><NE.Nu/><NE.Nu/><NE.L2"_2N _ /><NE.N _/><NE.N _0/><NE.N/><NE./@NuL20/>< NE.N _/>< NE.N0/2/4/ o"oH 0$|&|@SB46Q |"|@L /><NE. _N/><NE.Nu/6/4/ 2/ 0//><NE.& _PON/><NE.Nu/><nNE.Nu/><pNE.Nu/><NE.Nu0/2/4/ o"oH 0$|&|@SB46Q |"|@L /><NE. _N _ /><NE.N/><NE./@Nu/><NE.L2"_2N/><NE./HNu/><NE./HNu/><NE.@Nu _/><NE.N/><NE.?@Nu _0/><NE.N _0/>< NE.N/><NE.?@Nu _0/><NE.N/><"NE./@Nu _ /><$NE.N/><&NE.Nu _ /><(NE.N/><*NE.?@Nu _0/><,NE.N _ /><.NE.N/><0NE.Nu _" /><2NE.N/><8NE.?@Nu/><NE.?@Nu _0/><NE.N _B@/><4NE.NL//><6NE.""""&NL2H/><<NE.222"LxNLH/><:NE.`LH/><NE.222"LxN/><>NE.L""_"N _" /><@NE.N _B@/><BNE.N/><rNE.@Nu _B@/><tNE.N/><NE.@Nu _B@/><NE.N/><NE./@Nu/><DNE./@Nu o/><FNE. _XO"_2N _0/><HNE.N _"0/><JNE.N _"0/><LNE.N _0/><NNE.NLH/><PNE.22222LNLH02468/><RNE.LN"oH02468/><TNE.LL"XON/><XNE./@Nu _ /><ZNE.NL H/><\NE.22222LNN^NuHWINTL 3. "6F^5D!$ǐ^11Ӳ 0.INCLUDE tlasm/SYSEQU.TEXT 0.INCLUDE tlasm/SYSMACS.TEXT /.PROC chgDriveQueue,1 myRefNum .EQU 4 ;offset to refNum on stack *MOVEQ #DQElLnth,D0 ; get size of drive queue element *_NewPtr,SYS ; and allocate one *MOVE.W #0,DQFSID(A0) ; zero means local file system *MOVEQ #3,D0 ; call it drive number 3 *SWAP D0 *MOVE.W myRefNum(SP),D0 ; get my renum from the stack *_AddDrive *LEA Mparams,A0 ; point to params *_MountVol ; mount as a volume *MOVE.L (SP)+,A0 ; get rtn addr *ADDQ #2,SP ; strip arg *JMP (A0) ; back to the application Mparams .BLOCK 12,0 ; header *.WORD 0,0 ; completion routine (NIL) *.WORD 0 ; ioresult *.WORD 0,0 ; misc don't-cares *.WORD 3 ; drive num *.END 3. "6F^5D!$ǐ^ ! !  $Exec Pramdisk/ramstart %{no listing} %{default} Gramdisk/ramstart %{default} Aramdisk/changeQ %{no listing} %{default} Aramdisk/fixSP %{no listing} %{default} Aramdisk/ramdisk %{no listing} %{default} Lramdisk/ramstart obj/quickdraw obj/tooltraps obj/ostraps obj/macpaslib ramdisk/changeQ %{no more files} %{no listing} ramdisk/ramstart Rrmaker ramdisk/ramdef Rmaccom FYLramdisk/ramstart.rsrc ram start APPL %{default signature} %{no bundle bit} Q $EndExec 3. "6F^5D!$ǐ^ H H*.INCLUDE tlasm/SysEqu.Text ;____________________________________________________________________________ ; ; fixSp is installed in System resource as type INIT, and simply sets a low ; memory variable which determines where the loader sets top of stack ; ; not really of general interest, but the use of type INIT for installing your ; driver may be. Resources of type INIT are pieces of code which are ; loaded into the system heap and executed at system startup time. Resource ; ID must be less than 256 ; ; ; ; *.PROC fixSP ; sets bufPtr to reserve space for Ram Disk *MOVE.L #$28000,BufPtr *RTS *.END 3. "6F^5D!$ǐ^!!* ramstart resource definition file * * To create the RAM disk driver, exec the file ramdisk/exec. * This creates a single Mac resource file called 'ram start'. * Then use Resource Mover to move the DRVR and INIT resources * from ram start into System. * Warning: don't try booting your modified system disk on a 128K Mac. * Works OK on MacWorks, but Resource Mover does not, so do * your resource moving on a Mac. ramstart.Rsrc * definition for the application code: Type CODE %ramstart,0 * definitition for the ramdisk driver: Type DRVR #ramdisk!.ramdisk,10(64) * definition for the fixsp code: Type INIT = PACK %fixsp,3 3. "6F^5D!$ǐ^ӵ * ramstart resource definition file * * ramdisk/ramstart.Rsrc Type CODE %ramdisk/ramstart,0 Type DRVR #ramdisk/ramdisk!.ramdisk,10(64) Type INIT = PACK %ramdisk/fixsp,3 Od5P:H r^Ӳ; ___________________________________________________ ; ; MacIntosh RAM Disk Driver ; (c) Apple Computer 1983 ; ; This is the unofficial Mac ramdisk driver. Most useful on 512K Macs ; Written in Dec '83 my MDB ; ; Routines: ; ; Open -- Zero the ram and create a directory ; ; Prime -- read and write calls. Get correct info from read or write parameter ; block, and get or put the bytes. All calls are synchronous, since ; ram doesn't have a lot of latency. ; ; Close -- Not closable at present associated files: ; ; Other Files: ; ; Ramstart -- loads drvr and initalizes ; chgq - assembly support for ramstart ; fixsp -- assembly support for setting stack pointer in 512K mchines ; changeres - closes system resource and reopens on ramdisk ; ;_______________________________________________________________________ ,.NOLIST ,.INCLUDE tlasm/SysEqu.Text ,.INCLUDE tlasm/SysErr.Text ,.INCLUDE tlasm/SysMacs.Text ,.LIST ,.PROC rDiskDrvr,0 ; driver header: RamDrvr ,.WORD $4F00 ; Ram-based,read,write,Ctrl,Status ,.WORD 0,0 ; no delay or EMask ,.WORD 0 ; no menu ; Entry point offset table ,.WORD DiskOpen-RamDrvr ; open ,.WORD DiskPrime-RamDrvr ; prime ,.WORD allDone-RamDrvr ; just RTS for the rest ,.WORD allDone-RamDrvr ,.WORD allDone-RamDrvr ,.BYTE 9 ,.ASCII '.Ramdisk1' ; misc equates: $; myramBase .equ $00011000 $; myramSize .equ $2000 ; 4k for small Mac myramBase .equ $28000 myramSize .equ $50000 ; small Mac version assumes bufptr set to $11000 ; large Mac version assumes bufptr set to $28000 ; RamDisk Initialization routine ;_______________________________________________________________________ ; ; Routine: DiskOpen ; Arguments: A0 (input) -- pointer to open parameter block: ; A1 (input) -- DCE entry ptr for this driver ; D0 (output) -- result code ; Register use: A3 = pointer into cache DiskOpen MOVEM.L A0-A6/D0-D7,-(SP) 0; currently hardwired to top 320K or so of a 512K mac 0; or 4K for 128K Mac 0; zero the ram space: 0MOVE.L #myRamSize/4,D0 ; # longs in ram space 0SUBQ #1,D0 ; for DBRA 0MOVEQ #0,D1 0MOVE.L #myramBase,A3 ; A3 points to ram space zeros MOVE.L D1,(A3)+ ; zero mem 0DBRA D0,zeros 1; now put fake directory in ram space: 0LEA myDir,A0 ; directory data (source) 0MOVE.L #myramBase+1024,A1 ; base of disk + boot block space 0MOVE.L #63,D0 ; 63 bytes is dir size 0_blockMove ; move the directory 0MOVEM.L (SP)+,A0-A6/D0-D7 ; restore regs 0MOVEQ #0,D0 ; optimistic completion code DiskRts RTS ; RamDisk Prime routine ;_______________________________________________________________________ ; ; ; Arguments: A0 (input) -- pointer to request parameter block ; A1 (input) -- pointer to disk DCE; ; ; Register use: A3 -- position pointer in ramDisk ; A4 -- points to the buffer DiskPrime MOVEM.L A0-A4/D3-D7,-(SP) ; be conservative with regs ,MOVE.L #myRamBase,A3 ; A3 points to base of ram disk ,;pretend we're a block device: ,MOVE.L DCtlPosition(A1),D0 ; current byte position ,ANDI.L #$FFFFFE00,D0 ; truncate to make multiple of 512 ,; transform to an address in RAM Disk by adding offset to base ,ADD.L D0,A3 ,MOVE.L IOBuffer(A0),A4 ; get ptr to buffer ,; now do read or write in one big gulp: ,MOVE.L IOByteCount(A0),D0 ; num bytes to transfer ,MOVE.L D0,IONumDone(A0) ; show all done ,ADD.L #511,D0 ; round up to multiple of 512 ,ANDI.L #$FFFFFE00,D0 ; by adding and truncating ,CMPI.B #AWrCmd,IOTrap+1(A0) ; is IOTrap a write? ,BNE.S aRead aWrite MOVE.L A4,A0 ; buffer is source ,MOVE.L A3,A1 ; ramDisk is dest ,BRA.S moveBits aRead MOVE.L A3,A0 ; assume read. ramDisk is source ,MOVE.L A4,A1 ; buffer is dest MoveBits _blockMove ; move the bytes ,MOVEM.L (SP)+,A0-A4/D3-D7 ; restore regs ,MOVEQ #0,D0 ; good completion code (can't fail) allDone MOVE.L JIODone,-(SP) ; push addr of IODone ,RTS ; and jump through it ; master block data: currently hardwired myDir .BYTE $D2,$D7 ; mac password ,.LONG 0 ; creation date & time ,.LONG 0 ; last backup ,.WORD 0 ; attributes (Write OK) ,.WORD 0 ; # files in dir ,.WORD 4 ; 1st file directory block ,.WORD 4 ; # directory blocks ,.WORD myRamSize/2048 - 2 ; # allcation blocks ,.LONG 2048 ; bytes/allocation block (long) ,.LONG 16384 ; bytes/allocation clump ,.WORD 8 ; 1st data block ,.LONG 1 ; next avail file # -- longint ,.WORD myRamSize/2048-2 ; # alloc blocks free hardwired for now ,.BYTE 7 ; string length ,.ASCII 'RamDisk' ; volume name ,.WORD 20 ; round out the master block ;_______________________________________________________________________ ; ; Routine: DiskControl ; Arguments: A0 (input) -- pointer to control call parameter block: ; CSCode = 1 for KillIO ; 7 for Eject ; 8 for setting tag buffer ; ; ( Tag buffers not supported in RAM disk } ; really here for looks, since none of the control calls make any sense for ; a RAM disk ;_______________________________________________________________________ diskControl MOVE.W CSCode(A0),D0 ; get the control code ,SUBQ.W #KillCode,D0 ; is it KillIO? ,BNE.S @0 ; branch if not ,; KillIO makes no sense for synchronous devices, but ,; shame on you if you do a synchronous disk driver! ,MOVE SR,-(SP) ; a big NOP for the ram disk ,RTE ; note special return for KillIO @0 SUBQ.W #,D0 ; is it Eject? ,BNE.S @1 ; if not, go to the err return ,MOVEQ #ControlErr,D0 ; don't know how to eject ram! ,BRA.S allDone @1 MOVE #ControlErr,D0 ,BRA.S allDone ,.END 5P:H r^11PROGRAM ramStart; Uses {$U obj/Memtypes } Memtypes, %{$U obj/QuickDraw } QuickDraw, %{$U obj/OSIntf } OSIntf, %{$U obj/ToolIntf } ToolIntf; Const "RamResID = 10; VAR $code: INTEGER; $myHandle: handle; PROCEDURE chgDriveQueue(refNum : INTEGER); EXTERNAL; BEGIN { Main } "code := OpenDriver('.ramdisk'); { open the driver } "myHandle := getResource('DRVR',RamResID); { get handle to it } "detachResource(myHandle); { detach it } "chgDriveQueue(code); { install it in the drive queue } END. 3. "6F^5D!$ǐ^Ӳm,.INCLUDE tlasm/SysEqu.Text ,.INCLUDE tlasm/SysMacs.Text ,.PROC stuffBoot ; set boot drive to ram disk (Drive 3) G; also sets default drive to be drive3 ,MOVE.W #$3,BootDrive ; this low memory location is boot drive ,LEA parmBlock,A0 ; point to the param block ,MOVE.W #3,IODrvNum(A0) ; drive 3 to be default ,CLR.L IOVnPtr(A0) ,_SetVol ,RTS parmBlock .BLOCK IOQElSize,0 ; For setVol call ,.END O5PH r^OO; File: FSEqu.Text ;_______________________________________________________________________ ; ; External Routines: none ; ; Internal Routines: none ; ; Function: This file contains all file system equates. Currently ; contains equates which will go into SYSEQU.TEXT ; ; Modification History: ; 22 Dec 82 LAK I modify this file every day. ; 08 Feb 83 LAK Pared down RgSvArea to 56 bytes from 64; added FSTemp4 ; for Rename. ; 14 Feb 83 LAK Changed VCB dir wr prot to attributes word. ; 30 May 83 LAK Added FrcSync flag, DiskSwitch, ExtFS, FSQueue, CmdDone ; hook vectors. ; 05 Jan 83 LAK Switched equates for BufFlags and BufFBlk to correspond ; with reality as perceived by the ROM. ; 10 Jan 83 LAK Added FSClrWdLen -- length of fs globals cleared by boot blocks ; since DiskSwitched hook will eventually be installed by ROM ;_______________________________________________________________________ ; (c) 1983 Apple Computer, Inc. ; ; File System Equates ; ; General system equates: BtsPrBlk .EQU 12 ; twelve bits per block in the volume map. StrtDir .EQU 2 ; directory master block is block 2 BufSiz .EQU 512 ; standard file system buffer size in bytes HdrSiz .EQU 10 ; size of header prefixed to buffer BufModBit .EQU 7 ; dirty bit in high byte of buf tag word BufFNum .EQU -10 ; offset from buf start to file number longword BufFlags .EQU -6 ; offset from buf start to file flags word BufFBlk .EQU -4 ; offset from buf start to file block word BufTag .EQU -2 ; offset from buf start to tag word SigWord .EQU $D2D7 ; signature bytes expected on start block ; fixed location labels: (equivalent of zero page) CkdDB .EQU FileVars ; (2) used when searching the directory NxtDB .EQU CkdDB+2 MaxDB .EQU NxtDB+2 FlushOnly .EQU MaxDB+2 ; (1) flag used by UnMountVol,FlushVol, RegRsrc .EQU FlushOnly+1 ; (1) flag used by OpenRF, FileOpen FLckUnlck .EQU RegRsrc+1 ; (1) flag used by SetFilLock,RstFilLock FrcSync .EQU FLckUnlck+1 ; (1) when set, all fs calls are sync'ed NewMount .EQU FrcSync+1 ; (1) used by MountVol to flag new mounts DrMstrBlk .EQU NewMount+2 ; master directory block in a volume FCBSPtr .EQU DrMstrBlk+2 ; ptr to FCBs DefVCBPtr .EQU FCBSPtr+4 ; pointer to default VCB VCBQHdr .EQU DefVCBPtr+4 ; VCB queue header FSQHdr .EQU VCBQHdr+QHeadSize ; file system queue header (10 bytes) FSBusy .EQU FSQHdr+QFlags ; non-zero when the file system is busy FSQHead .EQU FSQHdr+QHead ; ptr to 1st queued cmd: 0 when queue empty FSQTail .EQU FSQHdr+QTail ; ptr to last queue element RgSvArea .EQU FSQHdr+QHeadSize ; reg save during async calls. ErCode .EQU RgSvArea+56 ; use this loc to report errors during async D; routines Params .EQU ErCode+2 ; 50 bytes long. For I/O parameter blocks. FSTemp8 .EQU Params+IOQElSize; used by rename FSTemp4 .EQU FSTemp8+8 ; used by rename, ckfilmod FSQueueHook .EQU FSTemp4+4 ; hook to capture all FS calls ExtFSHook .EQU FSQueueHook+4 ; command done hook DskSwtchHook .EQU ExtFSHook+4 ; hook for disk-switch dialog ReqstVol .EQU DskSwtchHook+4 ; ptr to VCB of off-line or ext fs volume toExtFS .EQU ReqstVol+4 ; hook for external file systems FSVarEnd .EQU toExtFS+4 ; end of file system variables FSVarLth .EQU FSVarEnd-FileVars FSClrWDLen .EQU FSQueueHook-FileVars ;length to clear in boot blocks ; Directory master block entries: (Prefix DR) DrSigWord .EQU 0 ; signature word DrCrDate .EQU 2 ; Creation date. DrLsBkUp .EQU 6 ; last backup date DrAtrb .EQU 10 ; volume attributes. bit 15=write(locked=1) DrNmFls .EQU 12 ; number files in directory DrDirSt .EQU 14 ; start dir (512-byte) block on diskette DrBlLn .EQU 16 ; length of dir in (512-byte) blocks DrNmAlBlks .EQU 18 ; number of blocks (of alloc size) this volume DrAlBlkSiz .EQU 20 ; min num of bytes to allocate (must be 512 mult) DrClpSiz .EQU 24 ; num of bytes to try to alloc as a clump DrAlBlSt .EQU 28 ; starting diskette (512-byte) block in block map DrNxtFNum .EQU 30 ; next free file number DrFreeBks .EQU 34 ; number of free blocks on this volume DrVN .EQU 36 ; volume name (including name length) MPTblStr .EQU 64 ; byte start position of map table within @; master dir block ; Volume Control Block equates: (prefix: VCB) VCBDirty .EQU 15 ; flags dirty bit (tst.w tests,clr.b clears) VCBWrProt .EQU 7 ; attrib write-protected bit (tst.b ATRB+1 tests) VCBFlags .EQU 6 ; flags word is first word after header ; first 66 bytes of VCB come directly from the directory master block VCBDInfoSt .EQU 8 ; leave room for 6-byte queue header VCBDILen .EQU 64 ; len of VCB data from master directory VCBSigWord .EQU 8 ; signature word VCBCrDate .EQU 10 ; Creation date. VCBLsBkUp .EQU 14 ; last backup date VCBAtrb .EQU 18 ; volume attributes. bit 15 = vol lock (1=locked) @; bit 7 = wr protect @; bit 6 = busy (1=busy) @; bits 0-2 = consistency prob VCBNmFls .EQU 20 ; number files in dir (low byte) VCBDirSt .EQU 22 ; start dir (512-byte) block on diskette VCBBlLn .EQU 24 ; length of dir in (512-byte) blocks VCBNmBlks .EQU 26 ; number of blocks (of alloc size) this device VCBNmAlBlks .EQU 26 ; (alternate label for a while) VCBAlBlkSiz .EQU 28 ; num of bytes in an allocation block VCBClpSiz .EQU 32 ; num of bytes to try to alloc as a clump VCBAlBlSt .EQU 36 ; starting diskette (512-byte) block in block map VCBNxtFNum .EQU 38 ; next free file number VCBFreeBks .EQU 42 ; number of free blocks on this volume VCBVN .EQU 44 ; volume name (including name length byte) VCBMaxNam .EQU 27 ; 27 byte max name length ; next 6 fields should be kept together VCBDrvNum .EQU 72 ; drive number for this VCB VCBDRefNum .EQU 74 ; driver refnum for this VCB VCBFSID .EQU 76 ; ID of file system handling this volume VCBVRefNum .EQU 78 ; unique refnum for this VCB VCBMAdr .EQU 80 ; volume map address VCBBufAdr .EQU 84 ; volume buffer address VCBMLen .EQU 88 ; length of volume map VCBDirIndex .EQU 90 ; directory index, block number used for VCBDirBlk .EQU 92 ; GetFileInfo searches by index VCBLength .EQU 94 ; VCB byte length ; File Entry equates: (prefix: Fl) ; (delete indication may be needed; for now just check VCB del fnum . . .) FlWrtFlag .EQU 0 ; write-allowed bit in flags byte (0 if allowed) FlTypMask .EQU $FE ; (user file-type in bits 1-7) FlFlags .EQU 0 ; bit 7=1 (used), bit 0=file lock flag FlTyp .EQU 1 ; file type (used as a name extension) FlUsrWds .EQU 2 ; user words for file. (16 bytes) FlFlNum .EQU 18 ; file number FlStBlk .EQU 22 ; Start file block (alloc blk size)(0000 if none) FlLgLen .EQU 24 ; File logical length in bytes (EOF) FlPyLen .EQU 28 ; File physical length in bytes FlRStBlk .EQU 32 ; Start file block, resource fork (0000 if none) FlRLgLen .EQU 34 ; File logical length (EOF), resource fork FlRPyLen .EQU 38 ; File physical length, resource fork FlCrDat .EQU 42 ; File creation date & time (32 bits in seconds) FlMdDat .EQU 46 ; last modification date & time (32 bits in seconds) FlNam .EQU 50 ; file name, starting with length byte FlNTLen .EQU 50 ; length of each file entry, excluding name ; File Control Block equates: (prefix: FCB) FCBModBit .EQU 7 ; dirty bit for FCB entry in FCBMdRByt FCBRscBit .EQU 1 ; 1 if this is resource part (in FCBMdRByt) FCBFlgRBit .EQU 9 ; resource bit in FCBFlags (word) FCBFlgWBit .EQU 8 ; write permissions bit in FCBFlags (word) FCBWrtBit .EQU 0 ; write permissions bit in FCBTypByt (1 if ok) WrRsMask .EQU $0300 ; rsrc/reg, write permissions mask FCBFlNm .EQU 0 ; FCB file number. Non-zero marks FCB used. FCBFlags .EQU 4 ; FCB flags FCBMdRByt .EQU 4 ; mod, write permissions, resource byte FCBTypByt .EQU 5 ; type byte FCBSBlk .EQU 6 ; File start block (in alloc size blks) FCBEOF .EQU 8 ; logical length or EOF in bytes FCBPLen .EQU 12 ; Physical file length in bytes FCBCrPs .EQU 16 ; current position within file. FCBVPtr .EQU 20 ; Absolute pointer to the corresponding VCB FCBBfAdr .EQU 24 ; file's buffer address. FCBFlPos .EQU 28 ; directory block this file is in FCBEntLen .EQU 30 ; each FCB is this long. W^I'4PH r^FTTEn;----------------------------------------------------------------- ; File GRAFEQU.TEXT - Macintosh graphics equates file. ; ; Written by Bud Tribble 26-May-81 ; ; All system graphic routines include this equate file. ; ; MODIFICATION HISTORY: ; ; BLT 2-Oct-81 For new LisaGraf ; AJH 31-Oct-81 Moved variables down to make room for driver variables ; alo 05-Feb-82 Lisagraf vars moved down to $800 for more system globals ; AJH 06-Jul-82 Added stuff for ObscureCursor ; LAK 26-Jul-82 Added JUPDATEPROC pointer to update event generator ; LAK 05-Sep-82 Added MaxX and MaxY equates ; AJH 15-Sep-82 Modified for new cursor interface ; LAK 16-Oct-82 updated for 512 dots ; AJH 20-Nov-82 added JournalFlag, font manager jump vectors ; AJH 02-Jan-83 added JournalHook ; SC 21-Jan-83 font scaling/coupling stuff ; SC 02-Jun-83 Added 3 vars for jerky cursors ; SC 23-Jan-83 changed JournalHook to journalRef ; AJH 11-Aug-83 added MScaleThresh, MScaleFactor ; LAK 13-Aug-83 changed above two to MScaleTbl, added MScaleOld ; LAK 18-Aug-83 changed above two to CrsrThresh and CrsrQuad. ; moved JCrsrTask here from Sysequ. ; LAK 20-Aug-83 Removed CrsrQuad. ;----------------------------------------------------------------- ;----------------------------------------------------------------- ; System Constants ;----------------------------------------------------------------- SCRNROWB .EQU 64 MaxX .EQU 512 MaxY .EQU 342 SCRNBYTES .EQU SCRNROWB*MaxY ;----------------------------------------------------------------- ; ; System Graphic Jump Vectors - Long pointers to ; system routine entry points. ; GRAFBEGIN .EQU $800 ;GRAF GLOBAL AREA ; JHIDECURSOR .EQU GRAFBEGIN JSHOWCURSOR .EQU JHIDECURSOR+4 JSHIELDCURSOR .EQU JSHOWCURSOR+4 JSCRNADDR .EQU JSHIELDCURSOR+4 JSCRNSIZE .EQU JSCRNADDR+4 JINITCRSR .EQU JSCRNSIZE+4 JSETCRSR .EQU JINITCRSR+4 JCRSROBSCURE .EQU JSETCRSR+4 JUPDATEPROC .EQU JCRSROBSCURE+4 LGRAFJUMP .EQU JUPDATEPROC+4 ;LAST VECTOR LOCATION ; ; System Graphic variables ; GRAFVAR .EQU LGRAFJUMP ;SYSTEM GRAPHIC VARIABLE AREA SCRNBASE .EQU GRAFVAR ;POINTER TO BASE OF SCREEN MTEMP .EQU SCRNBASE+4 ;POINT, TEMPORARY MOUSE COORDS RawMouse .EQU MTEMP+4 ; raw mouse coordinates (un-jerked) MOUSE .EQU RawMouse+4 ;POINT, MOUSE COORDS USED BY CURSOR CRSRPIN .EQU MOUSE+4 ;RECT, CURSOR PIN LIMITS CRSRRECT .EQU CRSRPIN+8 ;RECT, CURSOR HIT RECTANGLE THECRSR .EQU CRSRRECT+8 ;68 BYTES. CURSOR DATA, MASK, HOTSPOT CRSRADDR .EQU THECRSR+68 ;LONG, ADDR OF DATA UNDER CURSOR CRSRSAVE .EQU CRSRADDR+4 ;16 LONGS, DATA UNDER CURSOR CRSRVIS .EQU CRSRSAVE+64 ;BYTE, CURSOR VISIBLE FLAG CRSRBUSY .EQU CRSRVIS+1 ;BYTE, CURSOR LOCK-OUT FLAG CRSRNEW .EQU CRSRBUSY+1 ;BYTE, CURSOR CHANGED FLAG CRSRCOUPLE .EQU CRSRNEW+1 ;BYTE, CURSOR coupled flag CRSRSTATE .EQU CRSRCOUPLE+1 ;WORD, FOR NESTED CURSOR CALLS CRSROBSCURE .EQU CRSRSTATE+2 ;byte semaphore for obscure cursor CRSRSCALE .EQU CRSROBSCURE+1 ;byte cursor scale flag MouseMask .EQU CRSRSCALE+3 ; V-H mask for ANDing with mouse coordinates MouseOffset .EQU MouseMask+4 ; V-H offset for adding after anding above JournalFlag .EQU MouseOffset+4 ;flag for journaling JSwapFont .EQU JournalFlag+2 ;jump entry for FMSwapFont JFontInfo .EQU JSwapFont+4 ;jump entry for FMFontMetrics JournalRef .EQU JFontInfo+4 ;hook for journalling CrsrThresh .EQU JournalRef+4 ;threshold for mouse scaling JCrsrTask .EQU CrsrThresh+2 ;address of CrsrVBLTask ; NOTE -- JCrsrTask and CrsrThresh must be right before GrafEnd! GRAFEND .EQU JCrsrTask+4 ;end of graphics globals W^5PH r^zA ;----------------------------------------------------------------- ; ; --> GRAFTYPES.TEXT ; ; QUICKDRAW TYPE DECLARATIONS, USED BY ALL GRAPHICS ROUTINES ; SYMBOLS .EQU 0 FORMAC .EQU 1 NIL .EQU 0 ;IMPLEMENTATION VALUE OF NIL ;----------------------------------------------- ; ; QuickDraw VERBS: ; FRAME .EQU 0 PAINT .EQU 1 ERASE .EQU 2 INVERT .EQU 3 FILL .EQU 4 ;----------------------------------------------- ; ; QuickDraw transfer MODES: ; srcCopy .EQU 0 srcOr .EQU 1 srcXor .EQU 2 srcBic .EQU 3 notSrcCopy .EQU 4 notSrcOr .EQU 5 notSrcXor .EQU 6 notSrcBic .EQU 7 patCopy .EQU 8 patOr .EQU 9 patXor .EQU 10 patBic .EQU 11 notPatCopy .EQU 12 notPatOr .EQU 13 notPatXor .EQU 14 notPatBic .EQU 15 ;----------------------------------------------- ; ; QuickDraw Color Separation: ; normalBit .EQU 0 ;normal screen mapping inverseBit .EQU 1 ;inverse screen mapping redBit .EQU 4 ;RGB additive mapping greenBit .EQU 3 ;for photos from screen blueBit .EQU 2 cyanBit .EQU 8 ;CMYBk subtractive mapping magentaBit .EQU 7 ;for ink jet printer yellowBit .EQU 6 blackBit .EQU 5 blackColor .EQU 33 whiteColor .EQU 30 redColor .EQU 205 greenColor .EQU 341 blueColor .EQU 409 cyanColor .EQU 273 magentaColor .EQU 137 yellowColor .EQU 69 ;----------------------------------------------- ; ; OFFSETS WITHIN A POINT: ; V .EQU 0 ;WORD H .EQU 2 ;WORD ;----------------------------------------------- ; ; OFFSETS WITHIN A RECT: ; TOPLEFT .EQU 0 ;POINT BOTRIGHT .EQU 4 ;POINT TOP .EQU 0 ;INTEGER LEFT .EQU 2 ;INTEGER BOTTOM .EQU 4 ;INTEGER RIGHT .EQU 6 ;INTEGER ;----------------------------------------------- ; ; OFFSETS WITHIN A BITMAP: ; BASEADDR .EQU 0 ;LONG ROWBYTES .EQU 4 ;WORD BOUNDS .EQU 6 ;RECT ;----------------------------------------------- ; ; OFFSETS WITHIN A CURSOR: ; DATA .EQU 0 ;16 WORDS MASK .EQU 32 ;16 WORDS HOTSPOT .EQU 64 ;POINT ;----------------------------------------------- ; ; OFFSETS WITHIN A POLYGON: ; POLYSIZE .EQU 0 ;WORD, TOTAL BYTES POLYBBOX .EQU 2 ;RECT POLYPOINTS .EQU 10 ;ARRAY[0..0] OF Point ;----------------------------------------------- ; ; OFFSETS WITHIN A REGION: ; RGNSIZE .EQU 0 ;WORD, TOTAL BYTES RGNBBOX .EQU 2 ;RECT RGNDATA .EQU 10 ;START OF RGN DATA ;----------------------------------------------- ; ; OFFSETS WITHIN A PICTURE: ; PICSIZE .EQU 0 ;WORD, TOTAL BYTES PICFRAME .EQU 2 ;RECT PICDATA .EQU 10 ;START OF BYTE CODES ;----------------------------------------------- ; ; OFFSETS WITHIN QDProcs RECORD: ; textProc .EQU 0 ;PROCPTR lineProc .EQU textProc+4 ;PROCPTR rectProc .EQU lineProc+4 ;PROCPTR rRectProc .EQU rectProc+4 ;PROCPTR ovalProc .EQU rRectProc+4 ;PROCPTR arcProc .EQU ovalProc+4 ;PROCPTR polyProc .EQU arcProc+4 ;PROCPTR rgnProc .EQU polyProc+4 ;PROCPTR bitsProc .EQU rgnProc+4 ;PROCPTR commentProc .EQU bitsProc+4 ;PROCPTR txMeasProc .EQU commentProc+4 ;PROCPTR getPicProc .EQU txMeasProc+4 ;PROCPTR putPicProc .EQU getPicProc+4 ;PROCPTR ;----------------------------------------------- ; ; OFFSETS WITHIN A GRAFPORT: ; device .EQU 0 ;WORD portBits .EQU device+2 ;BITMAP portRect .EQU portBits+14 ;RECT visRgn .EQU portRect+8 ;RGNPTR clipRgn .EQU visRgn+4 ;RGNPTR bkPat .EQU clipRgn+4 ;PATTERN fillPat .EQU bkPat+8 ;PATTERN pnLoc .EQU fillPat+8 ;POINT pnSize .EQU pnLoc+4 ;POINT pnMode .EQU pnSize+4 ;WORD pnPat .EQU pnMode+2 ;PATTERN pnVis .EQU pnPat+8 ;WORD txFont .EQU pnVis+2 ;WORD txFace .EQU txFont+2 ;WORD txMode .EQU txFace+2 ;WORD txSize .EQU txMode+2 ;WORD spExtra .EQU txSize+2 ;Fixed Point fgColor .EQU spExtra+4 ;LONG bkColor .EQU fgColor+4 ;LONG colrBit .EQU bkColor+4 ;WORD patStretch .EQU colrBit+2 ;WORD picSave .EQU patStretch+2 ;handle rgnSave .EQU picSave+4 ;handle polySave .EQU rgnSave+4 ;handle grafProcs .EQU polySave+4 ;Pointer PORTREC .EQU grafProcs+4 ;SIZE OF A GRAFPORT PORTBOUNDS .EQU PORTBITS+BOUNDS ;----------------------------------------------------- ; ; OFFSETS IN A REGION STATE RECORD: ; RGNPTR .EQU 0 ;LONG DATAPTR .EQU RGNPTR+4 ;LONG SCANBUF .EQU DATAPTR+4 ;LONG SCANSIZE .EQU SCANBUF+4 ;WORD THISV .EQU SCANSIZE+2 ;WORD NEXTV .EQU THISV+2 ;WORD MINH .EQU NEXTV+2 ;WORD MAXH .EQU MINH+2 ;WORD LEFTH .EQU MAXH+2 ;WORD RGNREC .EQU LEFTH+2 ;SIZE OF A REGION RECORD ;----------------------------------------------------- ; ; Offsets in a PicSave record: ; thePic .EQU 0 ;PICHANDLE picMax .EQU thePic+4 ;INTEGER picClipRgn .EQU picMax+2 ;RgnHandle picBkPat .EQU picClipRgn+4 ;Pattern picTxFont .EQU picBkPat+8 ;WORD picTxFace .EQU picTxFont+2 ;Style picTxMode .EQU picTxFace+2 ;WORD picTxSize .EQU picTxMode+2 ;WORD picSpExtra .EQU picTxSize+2 ;Fixed Point picTxNumer .EQU picSpExtra+4 ;Point picTxDenom .EQU picTxNumer+4 ;Point picTxLoc .EQU picTxDenom+4 ;Point picPnLoc .EQU picTxLoc+4 ;Point picPnSize .EQU picPnLoc+4 ;Point picPnMode .EQU picPnSize+4 ;WORD picPnPat .EQU picPnMode+2 ;Pattern picFillPat .EQU picPnPat+8 ;Pattern picTheRect .EQU picFillPat+8 ;Rect picOvSize .EQU picTheRect+8 ;Point picOrigin .EQU picOvSize+4 ;Point picFgColor .EQU picOrigin+4 ;Long picBkColor .EQU picFgColor+4 ;Long picSaveRec .EQU picBkColor+4 ;total size in bytes ;----------------------------------------------------- ; ; QuickDraw GLOBAL VARIABLES: ; ; 52(A5) CONTAINS A POINTER TO THEPORT. ; ALL OTHER GLOBAL VARIABLES ARE EXPRESSED RELATIVE TO THEPORT. ; (.IF FORMAC GRAFGLOBALS .EQU 0 ;A5 OFFSET TO GLOBALPTR (.ELSE GRAFGLOBALS .EQU 52 ;A5 OFFSET TO GLOBALPTR (.ENDC ;----------------------------------------------------------- ; ; QuickDraw PUBLIC GLOBAL VARIABLES: ; thePort .EQU 0 ;GrafPtr white .EQU thePort-8 ;Pattern black .EQU white-8 ;Pattern gray .EQU black-8 ;Pattern ltGray .EQU gray-8 ;Pattern dkGray .EQU ltGray-8 ;Pattern arrow .EQU dkGray-68 ;Cursor screenBits .EQU arrow-14 ;BitMap randSeed .EQU screenBits-4 ;LONGINT ;------------------------------------------------------------ ; ; QuickDraw private global variables: ; wideOpen .EQU randSeed-4 ;RgnHandle wideMaster .EQU wideOpen-4 ;RgnPtr wideData .EQU wideMaster-10 ;Fake Region rgnBuf .EQU wideData-4 ;PointsHandle rgnIndex .EQU rgnBuf-2 ;INTEGER rgnMax .EQU rgnIndex-2 ;INTEGER playPic .EQU rgnMax-4 ;Long playIndex .EQU playPic-2 ;INTEGER; thePoly .EQU playIndex-4 ;POLYHANDLE polyMax .EQU thePoly-2 ;INTEGER patAlign .EQU polyMax-4 ;Point fontAdj .EQU patAlign-4 ;Fixed Point fontPtr .EQU fontAdj-4 ;long, ^FMOutput record fontData .EQU fontPtr-26 ;FMOutput record lastGrafGlob .EQU fontData grafSize .EQU 4-lastGrafGlob ;total size in bytes (.MACRO UNLINK ;-------------------------------------------------------------- ; ; UNLINK A6, STRIP PARAMETERS, AND RETURN. ; IF SYMBOLS=TRUE, THEN ALSO PUT ASCII FOR PROCEDURE IDENTIFIER. ; ; FIRST PARAM IS NUMBER OF BYTES OF STACK BIAS. ; SECOND PARAM IS PROCEDURE IDENTIFIER. ; (UNLK A6 ;RELEASE LOCAL VARIABLES (.IF %1=0 ;NO PARAMETERS ? (RTS ;THEN JUST RTS (.ELSE (.IF %1=4 ;4 BYTES OF PARAMS ? (MOVE.L (SP)+,(SP) ;YES, STRIP AND ADJUST RET ADDR (RTS (.ELSE ;NOT 0 OR 4 BYTES OF PARAMS (MOVE.L (SP)+,A0 ;POP RETURN ADDR INTO A0 (ADD #%1,SP ;STRIP PARAMETERS (JMP (A0) ;JUMP THRU A0 TO RETURN (.ENDC (.ENDC (.IF SYMBOLS ;DO WE WANT SYMBOLS ? (.ASCII %2 ;YES, PUT PROCEDURE IDENTIFIER (.ENDC (.ENDM (.MACRO FAKEHEAD ;-------------------------------------------------------------- ; ; FAKEHEAD, (no params) ; ; Puts in a LINKA6 NOP to fake out the debugger's symbol mechanism. ; (.IF SYMBOLS (LINK A6,#0 ;DO THE LINK (MOVE.L (SP)+,A6 ;UNDO THE LINK (.ENDC (.ENDM (.MACRO FAKETAIL ;-------------------------------------------------------------- ; ; FAKETAIL, 'ProcName' ; ; Fake out the debugger's symbol mechanism. ; Put FAKETAIL,'ProcName' after executable code. ; (.IF SYMBOLS (UNLK A6 ;RELEASE LOCAL VARIABLES (RTS ;THEN JUST RTS (.ASCII %1 ;YES, PUT PROCEDURE IDENTIFIER (.ENDC (.ENDM (.MACRO CHECKSTACK ;-------------------------------------------------------------- ; ; CHECKSTACK byteCount ; ; Does a TST.W to expand the stack if not enough room. ; Does nothing on the Mac version. ; NOTE: %1 param should be an even negative number. ; SLOP .EQU 256 (.IF FORMAC=0 (TST.W %1-SLOP(SP) ;EXPAND STACK (.ENDC (.ENDM 5HH r^EKRKR;---------------------------------------------------------------------- ; HeapDefs - Definitions for Macintosh Assembly Language Memory Manager. ; ; Supports multiple heap zones with mixed relocatable and non-relocatable ; storage blocks. ; ; Reorganized from code designed and written by Bud Tribble, 27-Nov-81, ; and maintained and modified by Angeline Lo, Larry Kenyon, ; and Andy Hertzfeld. ; ; Modification History: ; 17 Feb 83 LAK added dfltStackSize for defltApplLimit. ; 20 Mar 83 MPH changed memory size constants to support 512 K byte ; machine; added PtrMask and HandleMask to allow garbage ; in high byte of ptrs or handles passed to memory manager; ; removed "checking" conditional from ChkZone macro. ; 29 Mar 83 MPH added purgeProc and moverelProc entries to zone object. ; 10 Jun 83 MPH Removed Definition of Nil, use Nil from GrafTypes. ; 17 Jun 83 MPH Removed moveRelProc from Heap object, inserted spare. ; 21 Jun 83 MPH Put FreeList code under assembly switch: FList. ; 18 Jul 83 LAK Removed FreeList stuff completely; removed TLock, TPurge; ; removed Trap macro and check hook offsets. ; 30 Jul 83 LAK Added equates for PurgePtr and AllocPtr. Also added equates ; for Flags byte: FNSelCompct,FNoRvrAlloc,FNSelPurge,FRelAtEnd. ; 12 Aug 83 LAK Added ClearBit equate. ;---------------------------------------------------------------------- ; These constants control conditional assembly. Checking .Equ 0 ;check arguments and data structures Statistics .Equ 0 ;gather statistics on usage Robust .Equ 0 ;enables super-robust internal checks CountMPs .Equ 0 ;enables counting of master pointers DfltFlags .Equ 0 ;Checking is on when zone is init'd ; ; Constants: ; MinFree .EQU 12 ;12 byte minimum block size TagMask .EQU $C0000000 ;Mask for the 2-bit Tag Field BCOffMask .EQU $0F000000 ;Mask for the 4 bit Byte Count offset BCMask .EQU $00FFFFFF ;Mask for the 24 bit Byte Count PtrMask .EQU $00FFFFFF ;Mask pointer to low 24 bits HandleMask .EQU $00FFFFFF ;Mask handle to low 24 bits FreeTag .EQU $0 ;Tag for Free block NRelTag .EQU $40000000 ;Tag for Non-Relocatable block RelTag .EQU $80000000 ;Tag for Relocatable block MaxSize .EQU $800000 ;Max data block size is 512K bytes MinAddr .EQU $0 ;Min legal address MaxAddr .EQU $800000 ;Max legal address for 512K machine MaxMasters .EQU $1000 ;Ridiculously large allocation chunk size dfltMasters .EQU 32 ;Default to 32 master pointers dfltStackSize .EQU $00002000 ;8K size for stack mnStackSize .EQU $00000400 ;1K minimum size for stack ; ; Block Types ; tybkMask .EQU 3 ;Mask for block type tybkFree .EQU 0 ;Free Block tybkNRel .EQU 1 ;Non-Relocatable tybkRel .EQU 2 ;Relocatable ; ; Heap Zone Offsets: ; BkLim .EQU 0 ;Long, last block in zone PurgePtr .EQU 4 ;Long, roving purge pointer. HFstFree .EQU 8 ;Long, first free handle ZCBFree .EQU 12 ;Long, # of free bytes in zone GZProc .EQU 16 ;Long, pointer to grow zone procedure MAllocCnt .EQU 20 ;Word, # of master to allocate Flags .EQU 22 ;Word, Flags FOnCheck .EQU 0 ;Turn On Checking FChecking .EQU 1 ;Checking on FGZAlways .EQU 2 ;Set to 1 to force user GZ calls in noncrit cases FNGZResrv .EQU 3 ;Set to 1 to prevent GZ reservMem calls FNSelCompct .EQU 4 ;Use non-selective compact algorithm when 1. FNoRvrAlloc .EQU 5 ;Don't use rover allocation scheme when 1. FNSelPurge .EQU 6 ;Use non-selective purge algorithm when 1. FRelAtEnd .EQU 7 ;MakeBk packs rels at end of free bk when 1. cntRel .EQU 24 ;Word, # of allocated relocatable blocks maxRel .EQU 26 ;Word, max # of allocated rel. blocks. cntNRel .EQU 28 ;Word, # of allocated non-rel. blocks. maxNRel .EQU 30 ;Word, max # of allocated non-rel. blocks. cntEmpty .EQU 32 ;Word, # of empty handles cntHandles .EQU 34 ;Word, # of total handles minCBFree .EQU 36 ;Long, min # of bytes free. purgeProc .EQU 40 ;Long, pointer to purge warning procedure spare1 .EQU 44 ;Long, unused spare. AllocPtr .EQU 48 ;Long, roving allocation pointer. HeapData .EQU 52 ;Start of heap zone data MinZone .Equ HeapData+<4*MinFree>+<8*dfltMasters> ; ;Minimum size for Applic. Zone ; ; Block Offsets ; TagBC .EQU 0 ;Long, Tag and Byte Count field Handle .EQU 4 ;Long, handle to current data block BlkData .EQU 8 ;All Block Data Starts Here ; ; Heap Zone Default Sizes ; SysZoneSize .EQU $4000 ;16 K byte static sysZone size AppZoneSize .EQU $1800 ;6 K byte static appZone size ; ; Structure of InitZone argument table. ; StartPtr .EQU 0 ;Start address for zone. LimitPtr .EQU 4 ;Limit address for zone. CMoreMasters .EQU 8 ;Number of masters to allocate at time. PGrowZone .EQU 10 ;Points to the growZone procedure. ; ; Bit offset for system trap special functions ; TSysOrCurZone .EQU 10 ; Bit set implies System Zone @; bit clear implies Current Zone ClearBit .EQU 9 ; Bit set means clear allocated memory. ;---------------------------------------------------------------------- ; Macros ; 0.MACRO GetZ ;Get theZone into a register 2MOVE.L theZone,%1 0.ENDM 0.MACRO SetZ ;Set theZone with a register's value 2MOVE.L %1,theZone 0.ENDM 0.macro Equal 2.if Checking 2Move.L %1,-(SP) 2Move.L %2,-(SP) 2JSR EqualCheck 2.endc 0.endm 0.macro Even 2.if Checking 2MOVE.L %1,-(SP) 2JSR EvenCheck 2.endc 0.endm 0.macro Range 2.if Checking 2MOVE.L %1,-(SP) 2MOVE.L %2,-(SP) 2MOVE.L %3,-(SP) 2JSR RangeCheck 2.endc 0.endm 3. "6F^5D!$ǐ^; This mockup of the Pascal library MACPASLIB allows an assembly program to ; run standalone without the overhead of the normal Pascal library. This may ; either be included in the program source or linked with the assembled program. *.PROC MOCPASLIB *.DEF %_BEGIN *.DEF %_END *.DEF %_Term *.DEF %_INIT %_BEGIN: *CLR.L $10(SP) %_END: *RTS %_Term *MOVE.L (SP)+,A0 *LINK A5,#0 *JMP (A0) %_INIT: *MOVE.L (SP)+,A0 *UNLK A5 *JMP (A0) .END 3. "6F^5D!$ǐ^x; File: PackEqu ; ; This file contains all the equates needed for packages ;_______________________________________________________________________ ; ; ; Modification History: ; 3 Mar 84 RS Created on this date ;_______________________________________________________________________ ; (c) 1983 Apple Computer, Inc. ; ; Package Equates ; dskInit .EQU 2 ;Disk Initialization stdFile .EQU 3 ;Standard File flPoint .EQU 4 ;Floating-Point Arithmetic trFunc .EQU 5 ;Transcendental Functions intUtil .EQU 6 ;International Utilities bdConv .EQU 7 ;Binary/Decimal Conversion ;equates for STANDARD FILE PACKAGE putDlgID .EQU -3999 ;SFPutFile dialog template ID putSave .EQU 1 ;save button putCancel .EQU 2 ;cancel button putEject .EQU 5 ;eject button putDrive .EQU 6 ;drive button putName .EQU 7 ;editTExt item for file name getDlgID .EQU -4000 ;SFGetFile dialog template ID getOpen .EQU 1 ;open button getCancel .EQU 3 ;cancel button getEject .EQU 5 ;eject button getDrive .EQU 6 ;drive button getNmList .EQU 7 ;userItem for file name list getScroll .EQU 8 ;userItem for scroll bar ;reply record data structure rGood .EQU 0 ;ignore command if FALSE rType .EQU 2 ;file type rVolume .EQU 6 ;volume reference number rVersion .EQU 8 ;file's version number rName .EQU 10 ;file name ;routine selectors SFPutFile .EQU 1 SFPPutFile .EQU 3 SFGetFile .EQU 2 SFPGetFile .EQU 4 ;equates for DISK INITIALIZATION PACKAGE ;routine selectors DILoad .EQU 2 DIUnload .EQU 4 DIBadMount .EQU 0 DIFormat .EQU 6 DIVerify .EQU 8 DIZero .EQU 10 ;result codes are defined in sysequ ;equates for INTERNATIONAL PACKAGE ;routine selectors IUGetIntl .EQU 6 IUSetIntl .EQU 8 IUDateString .EQU 0 IUDatePString .EQU 14 IUTimeString .EQU 2 IUTimePString .EQU 16 IUMetric .EQU 4 IUMagString .EQU 10 IUMagIDString .EQU 12 ;data structures for International Utilities ;international 0 record decimalPt .EQU 0 ;ASCII character for decimal point thousSep .EQU 1 ;ASCII character for thousand separator listSep .EQU 2 ;ASCII character for list separator currSym .EQU 3 ;ASCII for currency symbol (3 bytes long) currFmt .EQU 6 ;currency format flags dateOrder .EQU 7 ;short date form - DMY,YMD, or MDY shrtDateFmt .EQU 8 ;date elements format flag dateSep .EQU 9 ;ASCII for date separator timecycle .EQU 10 ;indicates 12 or 24 hr cycle timeFmt .EQU 11 ;time elements format flags mornStr .EQU 12 ;ASCII for trailing string from 0:00 to 11:59 eveStr .EQU 16 ;ASCII for trailing string from 12:00 to 23:59 timeSep .EQU 20 ;ASCII for the time separator timeSuff .EQU 21 ;suffix string used in 24 hr mode metricSys .EQU 29 ;indicates metric or English system intl0Vers .EQU 30 ;version: high byte = country. low byte = vers ;International 1 record days .EQU 0 months .EQU 112 suppressDay .EQU 304 lngDateFmt .EQU 305 dayLeading0 .EQU 306 abbrLen .EQU 307 st0 .EQU 308 st1 .EQU 312 st2 .EQU 316 st3 .EQU 320 st4 .EQU 324 intl1Vers .EQU 328 localRtn .EQU 330 ;constants for manipulation of international resources} ;way to specify desired date format shortDate .EQU 0 longDate .EQU 1 abbrevDate .EQU 2 ;masks used for setting and testing currency format flags currLeadingZ .EQU 128 ;set if leading zero currTrailingZ .EQU 64 ;set if trailing zero currNegSym .EQU 32 ;set if minus sign for negative num, reset if parentheses} currSymLead .EQU 16 ;set if currency symbol leads, reset if trails} ;constants specifying absolute value of short date form MDY .EQU 0 ;month,day,year DMY .EQU 1 ;day,month,year YMD .EQU 2 ;year,month,day ;masks used for date element format flags century .EQU 128 ;set if century, reset if no century mntLdingZ .EQU 64 ;set if leading 0 for month dayLdingZ .EQU 32 ;set if leading zero for day ;masks used for time element format flags hrLeadingZ .EQU 128 ;set if leading zero for hours minLeadingZ .EQU 64 ;set if leading zero for minutes secLeadingZ .EQU 32 ;set if leading zero for seconds ;country codes for version numbers verUS .EQU 0 verFrance .EQU 1 verBritain .EQU 2 verGermany .EQU 3 verItaly .EQU 4 ;equates for BINARY-DECIMAL CONVERSION PACKAGE ;routine selectors NumToString .EQU 0 StringToNum .EQU 1 3. "6F^5D!$ǐ^p~!~! ; File: PackMacs.Text ;_______________________________________________________________________ ; ; PackMacs.Text - macros for the packages ; ; created by RS 5-30-84 ; ; ;macro for package invocation ; ; first arg is routine selector, second is the trap (.MACRO _PackCall (MOVE.W %1,-(SP) (%2 (.ENDM ;_______________________________________________________________________ ; ; Disk Initialization ; ;_______________________________________________________________________ *.MACRO _DILoad *_PackCall #DILoad,_Pack2 *.ENDM *.MACRO _DIUnLoad *_PackCall #DIUnLoad,_Pack2 *.ENDM *.MACRO _DIBadMount *_PackCall #DIBadMount,_Pack2 *.ENDM *.MACRO _DIFormat *_PackCall #DIFormat,_Pack2 *.ENDM *.MACRO _DIVerify *_PackCall #DIVerify,_Pack2 *.ENDM *.MACRO _DIZero *_PackCall #DIZero,_Pack2 *.ENDM ;_______________________________________________________________________ ; ; Standard File ; ;_______________________________________________________________________ *.MACRO _SFPutFile *_PackCall #SFPutFile,_Pack3 *.ENDM *.MACRO _SFPPutFile *_PackCall #SFPPutFile,_Pack3 *.ENDM *.MACRO _SFGetFile *_PackCall #SFGetFile,_Pack3 *.ENDM *.MACRO _SFPGetFile *_PackCall #SFPGetFile,_Pack3 *.ENDM ;_______________________________________________________________________ ; ; Interational Utilities ; ;_______________________________________________________________________ *.MACRO _IUGetIntl *_PackCall #IUGetIntl,_Pack6 *.ENDM *.MACRO _IUSetIntl *_PackCall #IUSetIntl,_Pack6 *.ENDM *.MACRO _IUDateString *_PackCall #IUDateString,_Pack6 *.ENDM *.MACRO _IUDatePString *_PackCall #IUDatePString,_Pack6 *.ENDM *.MACRO _IUTimeString *_PackCall #IUTimeString,_Pack6 *.ENDM *.MACRO _IUTimePString *_PackCall #IUTimePString,_Pack6 *.ENDM *.MACRO _IUMetric *_PackCall #IUMetric,_Pack6 *.ENDM *.MACRO _IUMagString *_PackCall #IUMagString,_Pack6 *.ENDM *.MACRO _IUMagIDString *_PackCall #IUMagIDString,_Pack6 *.ENDM ;_______________________________________________________________________ ; ; Binary-Decimal Conversion ;_______________________________________________________________________ *.MACRO _StringToNum *_PackCall #StringToNum,_Pack7 *.ENDM *.MACRO _NumToString *_PackCall #NumToString,_Pack7 *.ENDM W^65D!l D!l^AAG;------------------------------------------------------------------------------- ; These are the definitions for the Print code ;------------------------------------------------------------------------------- fPrDbgOK .EQU 1 ;Debug enable iPrDeapShit .EQU 29 ;Printcode DeapShit iPrAbort .EQU 128 ;Abort iPrRelease .EQU 2 ;Current version number of the code. ;------------------------------------------------------------------------------- ; These are misc Alert & Dialog constants ;------------------------------------------------------------------------------- iOK .EQU 1 ; OK Button iCancel .EQU 2 ; Cancel Button iPrStlDlg .EQU $E000 ; {-8192} Style Dialog iPrJobDlg .EQU $E001 ; {-8191} Job Dialog iPrCfgDlg .EQU $E002 ; {-8190} Configuration Dialog iPgFeedAx .EQU $E00A ; {-8182} Page Feed Dialog iPicSizAx .EQU $E00B ; {-8181} Pic Size Alert iIOAbrtAx .EQU $E00C ; {-8180} IO Timeout Alert ;------------------------------------------------------------------------------- ; The Private Print Globals; 16 bytes located at [SysEqu] PrintVars ;------------------------------------------------------------------------------- iPrErr .EQU 0 ;Current print error. Set to iPrAbort to abort printing. bDocLoop .EQU iPrErr+2 ;The Doc style: Draft, Spool, .., and .. H;Currently use low 2 bits; the upper 6 are for flags. bUser1 .EQU bDocLoop+1 lUser1 .EQU bUser1+1 lUser2 .EQU lUser1+4 lUser3 .EQU lUser2+4 iPrVarSize .EQU lUser3+4 ;The PrVar's size.[16] bDraftLoop .EQU 0 ;The DocLoop types bSpoolLoop .EQU 1 bUser1Loop .EQU 2 bUser2Loop .EQU 3 ;------------------------------------------------------------------------------- ; These are the PrDrvr constants. ;------------------------------------------------------------------------------- iPrDrvrID .EQU 2 ;Driver's ResID iPrDrvrRef .EQU $FFFD ;Driver's RefNum = NOT ResID iPrDrvrDev .EQU $FD00 ;Driver's QD Dev num = RefNum in Hi Byte, variant in lo iPrBitsCtl .EQU 4 ;The Bitmap Print Proc's ctl number lScreenBits .EQU $00000000 ;The Bitmap Print Proc's Screen Bitmap param lPaintBits .EQU $00000001 ;The Bitmap Print Proc's Paint [sq pix] param iPrIOCtl .EQU 5 ;The Raw Byte IO Proc's ctl number iPrEvtCtl .EQU 6 ;The PrEvent Proc's ctl number lPrEvtAll .EQU $00FFFFFD ;The PrEvent Proc's CParam for the entire screen lPrEvtTop .EQU $00FEFFFD ;The PrEvent Proc's CParam for the top folder iPrDevCtl .EQU 7 ;The PrDevCtl Proc's ctl number iPrReset .EQU 1 ;The PrDevCtl Proc's CParam for reset iPrPageEnd .EQU 2 ;The PrDevCtl Proc's CParam for end page iPrLineFeed .EQU 3 ;The PrDevCtl Proc's CParam for paper advance lPrLFSixth .EQU -1 ;The PrDevCtl Proc's CParam for 1/6 th inch paper advance lPrLFEighth .EQU -2 ;The PrDevCtl Proc's CParam for 1/8 th inch paper advance iFMgrCtl .EQU 8 ;The FMgr's Tail-hook ctl call iFMgrStat .EQU 8 ;The FMgr's Pre-hook status call ;------------------------------------------------------------------------------- ; Various Resource Types & ID's ;------------------------------------------------------------------------------- lPStrType .EQU $53545220 ;"STR ": Res type for the Pr Rsrc file name iPStrRFil .EQU $E000 ;Str -8192 is in SysRes & names the current printer lPrintType .EQU $50524543 ;"PREC": Res type for the hPrint records iPrintDef .EQU 0 ;Default hPrint iPrintLst .EQU 1 ;Last used hPrint iPrintDrvr .EQU 2 ;.Print's parameter record; not a Print rec lPfType .EQU $5046494C ;"PFIL" lPfSig .EQU $50535953 ;"PSYS" iPfIcon .EQU 140 ; lPrType .EQU $4150504C ;"APPL" lPrSig .EQU $50535953 ;"PSYS" iPrIcon .EQU 138 ; ;------------------------------------------------------------------------------- ; The Printing data structures ;------------------------------------------------------------------------------- ;Print Info Record: The parameters needed for page composition. ;------------------------------------------------------------------------------- iDev .EQU 0 ;Font mgr/QuickDraw device code iVRes .EQU iDev+2 ;Resolution of device, in device coordinates. iHRes .EQU iVRes+2 ; ..note: V before H => compatable with Point. rPage .EQU iHRes+2 ;The page (printable) rectangle in device coordinates. iPrInfoSize .EQU rPage+8 ;The PrInfo size.[14] ;------------------------------------------------------------------------------- ;Printer Style: The printer configuration and usage information. ;------------------------------------------------------------------------------- wDev .EQU 0 ;The drvr number. Hi byte=RefNum, Lo byte=variant. iPageV .EQU wDev+2 ;paper size in units of 1/iPrPgFract iPageH .EQU iPageV+2 ; ..note: V before H => compatable with Point. bPort .EQU iPageH+2 ;The IO port number. feed .EQU bPort+1 ;paper feeder type. iPrStlSize .EQU feed+1 ;The PrStl size.[8] ;------------------------------------------------------------------------------- ;Print eXtra Info: The print time eXtra information. ;------------------------------------------------------------------------------- iRowBytes .EQU 0 ;The Band's rowBytes. iBandV .EQU iRowBytes+2 ;Size of band, in device coordinates iBandH .EQU iBandV+2 ; ..note: V before H => compatable with Point. iDevBytes .EQU iBandH+2 ;Size for allocation. May be more than rBounds size! iBands .EQU iDevBytes+2 ;Number of bands per page. bPatScale .EQU iBands+2 ;Pattern scaling bULThick .EQU bPatScale+1 ;3 Underscoring parameters bULOffset .EQU bULThick+1 bULShadow .EQU bULOffset+1 scan .EQU bULShadow+1 ;Band scan direction bXInfoX .EQU scan+1 ;An eXtra byte. iPrXInfoSize .EQU bXInfoX+1 ;The PrXInfo size.[16] ;------------------------------------------------------------------------------- ;Print Job: Print "form" for a single print request. ;------------------------------------------------------------------------------- iFstPage .EQU 0 ;Page Range. iLstPage .EQU iFstPage+2 iCopies .EQU iLstPage+2 ;No. copies. bJDocLoop .EQU iCopies+2 ;Draft quality print flag fFromApp .EQU bJDocLoop+1 ;Printing from an App (not PrApp) flag pIdleProc .EQU fFromApp+1 ;The Proc called while waiting on IO etc. pFileName .EQU pIdleProc+4 ;Spool File Name: NIL for default. iFileVol .EQU pFileName+4 ;Spool File vol, set to 0 initially. bFileVers .EQU iFileVol+2 ;Spool File version, set to 0 initially. bJobX .EQU bFileVers+1 ;An eXtra byte. iPrJobSize .EQU bJobX+1 ;The PrJob size.[20] ;------------------------------------------------------------------------------- ;The universal 120 byte printing record ;------------------------------------------------------------------------------- iPrVersion .EQU 0 ;Printing software version PrInfo .EQU iPrVersion+2 ;the PrInfo data associated with the current style. rPaper .EQU PrInfo + iPrInfoSize ;The paper rectangle [offset from rPage]. PrStl .EQU rPaper + 8 ;This print request's style. PrInfoPT .EQU PrStl + iPrStlSize ;Print Time Imaging metrics PrXInfo .EQU PrInfoPT+ iPrInfoSize ;Print-time (expanded) Print info record. PrJob .EQU PrXInfo + iPrXInfoSize ;The Print Job request iPrintSize .EQU 120 ;The Print record size.[120] ;------------------------------------------------------------------------------- ;Print Port: A graf port, its procs, plus some extra. ;------------------------------------------------------------------------------- GPort .EQU 0 ;The Printer's graf port. GProcs .EQU 108 ;..and its procs lGParam1 .EQU GProcs+13*4 ;Some params: Our relocatable stuff etc. lGParam2 .EQU lGParam1+4 lGParam3 .EQU lGParam2+4 lGParam4 .EQU lGParam3+4 fOurPtr .EQU lGParam4+4 ;Whether the PrPort allocation was done by us. fOurBits .EQU fOurPtr+1 ;Whether the BitMap allocation was done by us. iPrPortSize .EQU fOurBits+1 ;The PrPort size.[178] ;------------------------------------------------------------------------------- ;Print Status: Runtime status for PrPicFile & PrPic procs. ;------------------------------------------------------------------------------- iTotPages .EQU 0 ;Total pages in Print File. iCurPage .EQU iTotPages+2 ;Current page number iTotCopies .EQU iCurPage+2 ;Total copies requested iCurCopy .EQU iTotCopies+2 ;Current copy number iTotBands .EQU iCurCopy+2 ;Total bands per page. iCurBand .EQU iTotBands+2 ;Current band number fPgDirty .EQU iCurBand+2 ;True if current page has been written to. fImaging .EQU fPgDirty+1 ;Set while in band's DrawPic call. hPrint .EQU fImaging+1 ;Handle to the active Printer record pPrPort .EQU hPrint+4 ;Ptr to the active PrPort hPic .EQU pPrPort+4 ;Handle to the active Picture iPrStatSize .EQU hPic+4 ;The PrStatus size.[26] ;------------------------------------------------------------------------------- ; These are the constants for using resources to swap in the non-driver ; print code. Three numbers are needed: ; ResType ; ResID ; Offset into the seg's jump table ; ; The offset is really a formatted Long that contains three fields: ; Frame Size; Unlock flag; Offset into the seg's jump table ; We could use the topmost byte for further stuff: a stack adjust for ; storing the registers needed by the link code so that it would be re-entrant. ;------------------------------------------------------------------------------- lPDefType .EQU $50444546 ;Pr Resource TYPE: "PDEF" iPrDraftID .EQU 0 ;Pr Draft Resource ID iPrSpoolID .EQU 1 ;Pr Spool Resource ID iPrUser1ID .EQU 2 ;Pr Spare1 Resource ID iPrUser2ID .EQU 3 ;Pr Spare2 Resource ID lOpenDoc .EQU $000C0000 ;PrOpenDoc JumpTable offset lCloseDoc .EQU $00048004 ;PrCloseDoc JumpTable offset lOpenPage .EQU $00080008 ;PrOpenPage JumpTable offset lClosePage .EQU $0004000C ;PrClosePage JumpTable offset iPrDlgsID .EQU 4 ;Pr Dialogs Resource ID lDefault .EQU $00048000 ;PrintDefault JumpTable offset lStlDialog .EQU $00048004 ;PrStlDialog JumpTable offset lJobDialog .EQU $00048008 ;PrJobDialog JumpTable offset lStlInit .EQU $0004000C ;PrStlInit JumpTable offset lJobInit .EQU $00040010 ;PrJobInit JumpTable offset lDlgMain .EQU $00088014 ;PrDlgMain JumpTable offset lPrValidate .EQU $00048018 ;PrintValidate JumpTable offset lPrJobMerge .EQU $0008801C ;PrintValidate JumpTable offset iPrPicID .EQU 5 ;Pic Printing Resource ID lPrPicFile .EQU $00148000 ;PrPicFile JumpTable offset ;lPrPic .EQU $00148004 ;PrPic JumpTable offset iCfgDlgID .EQU 6 ;Configuration proc Resource ID lCfgDialog .EQU $00008000 ;PrCfgDialog JumpTable offset iPrHackID .EQU 7 ;The "Oops, I Forgot" Resource ID lPrHack .EQU $000C8000 ;PrHack JumpTable offset ;------------------------------------------------------------------------------- 5PH r^((;File QuickMacs.Text ;------------------------------------------------ ; ; QuickDraw Assembly Language Interface ; ; These macros expand into toolBox traps allowing ; a convenient, symbolic QuickDraw interface for the ; assembly language programmer. ; ; Version for ROM 2.0 -- Februrary 10, 1983 ; updated for ROM 2.4 -- Mar 16, 1983 ; regenerated for ROM 4.0 -- June 3, 1983 ; ;------------------------------------------------ 0.MACRO _InitCurs 0.WORD $A850 0.ENDM 0.MACRO _SetCurso 0.WORD $A851 0.ENDM 0.MACRO _HideCurs 0.WORD $A852 0.ENDM 0.MACRO _ShowCurs 0.WORD $A853 0.ENDM 0.MACRO _ShieldCu 0.WORD $A855 0.ENDM 0.MACRO _ObscureC 0.WORD $A856 0.ENDM 0.MACRO _BitAnd 0.WORD $A858 0.ENDM 0.MACRO _BitXOr 0.WORD $A859 0.ENDM 0.MACRO _BitNot 0.WORD $A85A 0.ENDM 0.MACRO _BitOr 0.WORD $A85B 0.ENDM 0.MACRO _BitShift 0.WORD $A85C 0.ENDM 0.MACRO _BitTst 0.WORD $A85D 0.ENDM 0.MACRO _BitSet 0.WORD $A85E 0.ENDM 0.MACRO _BitClr 0.WORD $A85F 0.ENDM 0.MACRO _Random 0.WORD $A861 0.ENDM 0.MACRO _ForeColo 0.WORD $A862 0.ENDM 0.MACRO _BackColo 0.WORD $A863 0.ENDM 0.MACRO _ColorBit 0.WORD $A864 0.ENDM 0.MACRO _GetPixel 0.WORD $A865 0.ENDM 0.MACRO _StuffHex 0.WORD $A866 0.ENDM 0.MACRO _LongMul 0.WORD $A867 0.ENDM 0.MACRO _FixMul 0.WORD $A868 0.ENDM 0.MACRO _FixRatio 0.WORD $A869 0.ENDM 0.MACRO _HiWord 0.WORD $A86A 0.ENDM 0.MACRO _LoWord 0.WORD $A86B 0.ENDM 0.MACRO _FixRound 0.WORD $A86C 0.ENDM 0.MACRO _InitPort 0.WORD $A86D 0.ENDM 0.MACRO _InitGraf 0.WORD $A86E 0.ENDM 0.MACRO _OpenPort 0.WORD $A86F 0.ENDM 0.MACRO _LocalToG 0.WORD $A870 0.ENDM 0.MACRO _GlobalTo 0.WORD $A871 0.ENDM 0.MACRO _GrafDevi 0.WORD $A872 0.ENDM 0.MACRO _SetPort 0.WORD $A873 0.ENDM 0.MACRO _GetPort 0.WORD $A874 0.ENDM 0.MACRO _SetPBits 0.WORD $A875 0.ENDM 0.MACRO _PortSize 0.WORD $A876 0.ENDM 0.MACRO _MovePort 0.WORD $A877 0.ENDM 0.MACRO _SetOrigi 0.WORD $A878 0.ENDM 0.MACRO _SetClip 0.WORD $A879 0.ENDM 0.MACRO _GetClip 0.WORD $A87A 0.ENDM 0.MACRO _ClipRect 0.WORD $A87B 0.ENDM 0.MACRO _BackPat 0.WORD $A87C 0.ENDM 0.MACRO _ClosePor 0.WORD $A87D 0.ENDM 0.MACRO _AddPt 0.WORD $A87E 0.ENDM 0.MACRO _SubPt 0.WORD $A87F 0.ENDM 0.MACRO _SetPt 0.WORD $A880 0.ENDM 0.MACRO _EqualPt 0.WORD $A881 0.ENDM 0.MACRO _StdText 0.WORD $A882 0.ENDM 0.MACRO _DrawChar 0.WORD $A883 0.ENDM 0.MACRO _DrawStri 0.WORD $A884 0.ENDM 0.MACRO _DrawText 0.WORD $A885 0.ENDM 0.MACRO _TextWidt 0.WORD $A886 0.ENDM 0.MACRO _TextFont 0.WORD $A887 0.ENDM 0.MACRO _TextFace 0.WORD $A888 0.ENDM 0.MACRO _TextMode 0.WORD $A889 0.ENDM 0.MACRO _TextSize 0.WORD $A88A 0.ENDM 0.MACRO _GetFontI 0.WORD $A88B 0.ENDM 0.MACRO _StringWi 0.WORD $A88C 0.ENDM 0.MACRO _CharWidt 0.WORD $A88D 0.ENDM 0.MACRO _SpaceExt 0.WORD $A88E 0.ENDM 0.MACRO _StdLine 0.WORD $A890 0.ENDM 0.MACRO _LineTo 0.WORD $A891 0.ENDM 0.MACRO _Line 0.WORD $A892 0.ENDM 0.MACRO _MoveTo 0.WORD $A893 0.ENDM 0.MACRO _Move 0.WORD $A894 0.ENDM 0.MACRO _Moov 0.WORD $A894 0.ENDM 0.MACRO _HidePen 0.WORD $A896 0.ENDM 0.MACRO _ShowPen 0.WORD $A897 0.ENDM 0.MACRO _GetPenSt 0.WORD $A898 0.ENDM 0.MACRO _SetPenSt 0.WORD $A899 0.ENDM 0.MACRO _GetPen 0.WORD $A89A 0.ENDM 0.MACRO _PenSize 0.WORD $A89B 0.ENDM 0.MACRO _PenMode 0.WORD $A89C 0.ENDM 0.MACRO _PenPat 0.WORD $A89D 0.ENDM 0.MACRO _PenNorma 0.WORD $A89E 0.ENDM 0.MACRO _StdRect 0.WORD $A8A0 0.ENDM 0.MACRO _FrameRec 0.WORD $A8A1 0.ENDM 0.MACRO _PaintRec 0.WORD $A8A2 0.ENDM 0.MACRO _EraseRec 0.WORD $A8A3 0.ENDM 0.MACRO _InverRe 0.WORD $A8A4 0.ENDM 0.MACRO _FillRect 0.WORD $A8A5 0.ENDM 0.MACRO _EqualRec 0.WORD $A8A6 0.ENDM 0.MACRO _SetRect 0.WORD $A8A7 0.ENDM 0.MACRO _OffSetRe 0.WORD $A8A8 0.ENDM 0.MACRO _InSetRec 0.WORD $A8A9 0.ENDM 0.MACRO _SectRect 0.WORD $A8AA 0.ENDM 0.MACRO _UnionRec 0.WORD $A8AB 0.ENDM 0.MACRO _Pt2Rect 0.WORD $A8AC 0.ENDM 0.MACRO _PtInRect 0.WORD $A8AD 0.ENDM 0.MACRO _EmptyRec 0.WORD $A8AE 0.ENDM 0.MACRO _StdRRect 0.WORD $A8AF 0.ENDM 0.MACRO _FrameRou 0.WORD $A8B0 0.ENDM 0.MACRO _PaintRou 0.WORD $A8B1 0.ENDM 0.MACRO _EraseRou 0.WORD $A8B2 0.ENDM 0.MACRO _InverRo 0.WORD $A8B3 0.ENDM 0.MACRO _FillRoun 0.WORD $A8B4 0.ENDM 0.MACRO _StdOval 0.WORD $A8B6 0.ENDM 0.MACRO _FrameOva 0.WORD $A8B7 0.ENDM 0.MACRO _PaintOva 0.WORD $A8B8 0.ENDM 0.MACRO _EraseOva 0.WORD $A8B9 0.ENDM 0.MACRO _InvertOv 0.WORD $A8BA 0.ENDM 0.MACRO _FillOval 0.WORD $A8BB 0.ENDM 0.MACRO _SlopeFromAngle 0.WORD $A8BC 0.ENDM 0.MACRO _StdArc 0.WORD $A8BD 0.ENDM 0.MACRO _FrameArc 0.WORD $A8BE 0.ENDM 0.MACRO _PaintArc 0.WORD $A8BF 0.ENDM 0.MACRO _EraseArc 0.WORD $A8C0 0.ENDM 0.MACRO _InvertAr 0.WORD $A8C1 0.ENDM 0.MACRO _FillArc 0.WORD $A8C2 0.ENDM 0.MACRO _PtToAngl 0.WORD $A8C3 0.ENDM 0.MACRO _AngleFromSlope 0.WORD $A8C4 0.ENDM 0.MACRO _StdPoly 0.WORD $A8C5 0.ENDM 0.MACRO _FramePol 0.WORD $A8C6 0.ENDM 0.MACRO _PaintPol 0.WORD $A8C7 0.ENDM 0.MACRO _ErasePol 0.WORD $A8C8 0.ENDM 0.MACRO _InvertPo 0.WORD $A8C9 0.ENDM 0.MACRO _FillPoly 0.WORD $A8CA 0.ENDM 0.MACRO _OpenPoly 0.WORD $A8CB 0.ENDM 0.MACRO _ClosePgon 0.WORD $A8CC 0.ENDM 0.MACRO _KillPoly 0.WORD $A8CD 0.ENDM 0.MACRO _OffSetPo 0.WORD $A8CE 0.ENDM 0.MACRO _PackBits 0.WORD $A8CF 0.ENDM 0.MACRO _UnpackBi 0.WORD $A8D0 0.ENDM 0.MACRO _StdRgn 0.WORD $A8D1 0.ENDM 0.MACRO _FrameRgn 0.WORD $A8D2 0.ENDM 0.MACRO _PaintRgn 0.WORD $A8D3 0.ENDM 0.MACRO _EraseRgn 0.WORD $A8D4 0.ENDM 0.MACRO _InverRgn 0.WORD $A8D5 0.ENDM 0.MACRO _FillRgn 0.WORD $A8D6 0.ENDM 0.MACRO _NewRgn 0.WORD $A8D8 0.ENDM 0.MACRO _DisposRgn 0.WORD $A8D9 0.ENDM 0.MACRO _OpenRgn 0.WORD $A8DA 0.ENDM 0.MACRO _CloseRgn 0.WORD $A8DB 0.ENDM 0.MACRO _CopyRgn 0.WORD $A8DC 0.ENDM 0.MACRO _SetEmpty 0.WORD $A8DD 0.ENDM 0.MACRO _SetRecRgn 0.WORD $A8DE 0.ENDM 0.MACRO _RectRgn 0.WORD $A8DF 0.ENDM 0.MACRO _OfSetRgn 0.WORD $A8E0 0.ENDM 0.MACRO _InSetRgn 0.WORD $A8E1 0.ENDM 0.MACRO _EmptyRgn 0.WORD $A8E2 0.ENDM 0.MACRO _EqualRgn 0.WORD $A8E3 0.ENDM 0.MACRO _SectRgn 0.WORD $A8E4 0.ENDM 0.MACRO _UnionRgn 0.WORD $A8E5 0.ENDM 0.MACRO _DiffRgn 0.WORD $A8E6 0.ENDM 0.MACRO _XOrRgn 0.WORD $A8E7 0.ENDM 0.MACRO _PtInRgn 0.WORD $A8E8 0.ENDM 0.MACRO _RectInRg 0.WORD $A8E9 0.ENDM 0.MACRO _StdBits 0.WORD $A8EB 0.ENDM 0.MACRO _CopyBits 0.WORD $A8EC 0.ENDM 0.MACRO _ScrollRe 0.WORD $A8EF 0.ENDM 0.MACRO _SetStdPr 0.WORD $A8EA 0.ENDM 0.MACRO _StdTxMea 0.WORD $A8ED 0.ENDM 0.MACRO _StdGetPi 0.WORD $A8EE 0.ENDM 0.MACRO _StdPutPi 0.WORD $A8F0 0.ENDM 0.MACRO _StdComme 0.WORD $A8F1 0.ENDM 0.MACRO _PicComme 0.WORD $A8F2 0.ENDM 0.MACRO _OpenPict 0.WORD $A8F3 0.ENDM 0.MACRO _ClosePic 0.WORD $A8F4 0.ENDM 0.MACRO _KillPict 0.WORD $A8F5 0.ENDM 0.MACRO _DrawPict 0.WORD $A8F6 0.ENDM 0.MACRO _ScalePt 0.WORD $A8F8 0.ENDM 0.MACRO _MapPt 0.WORD $A8F9 0.ENDM 0.MACRO _MapRect 0.WORD $A8FA 0.ENDM 0.MACRO _MapRgn 0.WORD $A8FB 0.ENDM 0.MACRO _MapPoly 0.WORD $A8FC 0.ENDM 3. "6F^4D!$ǐ^XQ;File ResEqu.TEXT ;----------------------------------------------------- ; ; Standard System Resource Type and ID Definitions ; ; written by Andy Hertzfeld 28-Dec-82 ; ; Here are the standard resources defined by the system, ; listed by their type class. ; ; ; Modification History: ; ; AJH 06-Mar-83 Added FWID resource class ; BLH 06-Mar-83 Added Keymap resource class and standard resources ; AJH 03-Jun-83 KEYM -> KEYC ; AJH 07-Jul-83 Made it consistent with documentation ; AJH 05-Sep-83 Added TextRType ; ;------------------------------------------------------ ;------------------------------------------------ ; ; TYPE "PAT " -- Standard Pattern Definitions ; (also "PAT#") ; ;------------------------------------------------ PatRType .EQU $50415420 ;"PAT " resource type PatLRType .EQU $50415423 ;"PAT#" resource type ; patterns 0-15 are a gray scale WhitePat .EQU 0 ;white is pattern 0 LtGrayPat .EQU 4 ;light gray GrayPat .EQU 8 ;50-50 gray is 8 DkGrayPat .EQU 12 ;dark gray BlackPat .EQU 15 ;black is pattern 15 DeskPatID .EQU 16 ;desk pattern is pattern 16 SBarPatID .EQU 17 ;scrollBar pattern is 17 ;------------------------------------------------ ; ; TYPE "PICT" and "TEXT" -- Standard Scrap Types ; ;------------------------------------------------ PicRType .EQU $50494354 ;"PICT" -- Picture resource type TextRType .EQU $54455854 ;"TEXT" -- Text resource type ;------------------------------------------------ ; ; TYPE "ICON" -- Standard Icon Definitions ; ;------------------------------------------------ IconRType .EQU $49434F4E ;"ICON" -- resource class ; standard system-defined icons StopIcon .EQU 0 ;Stop icon NoteIcon .EQU 1 ;Note icon CtnIcon .EQU 2 ;Caution icon ;------------------------------------------------ ; ; TYPES "WDEF,MDEF,CDEF" ; ; -- ToolBox Object Definition Procedures ; ;------------------------------------------------ WDefRType .EQU $57444546 ;"WDEF" -- reosurce class MDefRType .EQU $4D444546 ;"MDEF" -- resource type CDefRType .EQU $43444546 ;"CDEF"--resource class ; standard window definition procedures DocumentProc .EQU 0 ;standard document DBoxProc .EQU 1 ;dialog box (document without titleBar) RDocProc .EQU 16 ;document with rounded corners ; standard menu definition procedures TextMenuProc .EQU 0 ;the one we know and love PatMenuProc .EQU 1 ;menu for displaying patterns ; standard control definition procedures PushButProc .EQU 0 ;standard rounded-corner pushButtons CheckBoxProc .EQU 1 ;standard check-box type buttons RadioButProc .EQU 2 ;almost the same as checkBox (different check) ScrollBarProc .EQU 16 ;standard scrollBar ;------------------------------------------------ ; ; TYPE "FONT" -- Standard Font Definitions ; ;------------------------------------------------ FontRType .EQU $464F4E54 ;"FONT" -- resource class FWidRType .EQU $46574944 ;"FWID" -- just like font with null strike ; here are a few standard font ID's. These are just the most common, for ; a complete choice, include "MoreFonts.TEXT" Cream10 .EQU 0 ;ROM font StdFont .EQU 1 ;one maps into application standard font ;------------------------------------------------ ; ; TYPE "DRVR" -- Standard Driver Definitions ; ;------------------------------------------------ DrvrRType .EQU $44525652 ;"DRVR" -- resource type ; ; drivers are referenced by name, so there are no standard ; resource IDs for them. ; ;------------------------------------------------ ; ; TYPE "KEYC" -- Standard Keyboard Mapping Procs ; ;------------------------------------------------ KeyCType .EQU $4B455943 ;"KEYC" -- resource type ;Standard keyboard drivers StdKbd .EQU 0 ;Standard keyboard driver ;------------------------------------------------ ; ; TYPE "CURS" -- Standard Cursor Definitions ; ;------------------------------------------------ CursRType .EQU $43555253 ;"CURS" -- resource type ; standard cursor definitions ArrowCursor .EQU 0 ;slanted arrow IBeamCursor .EQU 1 ;text selection cursor CrossCursor .EQU 2 ;for structured selection PlusCursor .EQU 3 ;for drawing graphics HourCursor .EQU 4 ;for indicating a long delay ;------------------------------------------------ ; ; TYPE "STR " -- Standard String (BuzzWord) Definitions ; ;------------------------------------------------ StringRType .EQU $53545220 ;"STR " -- resource class ; standard strings (none are currently defined) ;----------------------------------------------------- ; ; TYPEs "WIND,MENU,CNTL,MBAR" -- Standard ToolBox Objects ; ;----------------------------------------------------- WindRType .EQU $57494E44 ;"WIND" -- resource type MenuRType .EQU $4D454E55 ;"MENU" -- resource type MBarRType .EQU $4D424152 ;"MBAR" -- resource type CtrlRType .EQU $434E544C ;"CNTL" -- resource type ; no standard windows or menus are defined yet ; Standard Control Definitions OKButton .EQU 1 ;OK button CancelButton .EQU 2 ;Cancel button ;---------------------------------------------------------- ; ; TYPE "CODE" -- Code Segments ; ;---------------------------------------------------------- CodeRType .EQU $434F4445 ;"CODE" for code segments (programs!) ;---------------------------------------------------------- ; ; TYPE "ALRT,DLOG,DITL" -- Alert and Dialog Definitions ; ;---------------------------------------------------------- AlertType .EQU $414C5254 ;"ALRT" -- resource class DilogType .EQU $444C4F47 ;"DLOG" -- resource class ItmLstType .EQU $4449544C ;"DITL" -- dialog item list ; standard system alerts (none are defined yet) ; standard system dialogs (none are defined yet) A 7O^إ̥4PH r@^;----------------------------------------------------------- ; ; These macros give assembly language access to the Mac ; floating-point arithmetic routines. The arithmetic has ; just one entry point. It is typically accessed through ; the tooltrap _FP68K, although a custom version of the ; package may be linked as an object file, in which case ; the entry point is the label %FP68K. ; ; All calls to the arithmetic take the form: ; PEA ; PEA ; MOVE.W ,-(SP) ; _FP68K ; ; All operands are passed by address. The word ; specifies the instruction analogously to a 68000 machine ; instruction. Depending on the instruction, there may be ; from one to three operand addresses passed. ; ; This definition file specifies details of the ; word and the floating point state word, and defines ; some handy macros. ; ; Modification history: ; 29AUG82: WRITTEN BY JEROME COONEN ; 13OCT82: FB___ CONSTRANTS ADDED (JTC) ; 28DEC82: LOGB, SCALB ADDED, INF MODES OUT (JTC). ; 29APR83: ABS, NEG, CPYSGN, CLASS ADDED (JTC). ; 03MAY83: NEXT, SETXCP ADDED (JTC). ; 28MAY83: ELEMENTARY FUNCTIONS ADDED (JTC). ; 04JUL83: SHORT BRANCHES, TRIG AND RAND ADDED (JTC). ; 01NOV83: PRECISION CONTROL MADE A MODE (JTC). ; ;----------------------------------------------------------- ;----------------------------------------------------------- ; This constant determines whether the floating point unit ; is accessed via the system dispatcher after an A-line ; trap, or through a direct subroutine call to a custom ; version of the package linked directly to the application. ;----------------------------------------------------------- ATRAP .EQU 1 ;0 for JSR and 1 for A-line BTRAP .EQU 1 ;0 for JSR and 1 for A-line (.MACRO JSRFP (.IF ATRAP (_FP68K (.ELSE (.REF FP68K (JSR FP68K (.ENDC (.ENDM (.MACRO JSRELEMS (.IF BTRAP (_ELEMS68K (.ELSE (.REF ELEMS68K (JSR ELEMS68K (.ENDC (.ENDM ;----------------------------------------------------------- ; OPERATION MASKS: bits $001F of the operation word ; determine the operation. There are two rough classes of ; operations: even numbered opcodes are the usual ; arithmetic operations and odd numbered opcodes are non- ; arithmetic or utility operations. ;----------------------------------------------------------- FOADD .EQU $0000 FOSUB .EQU $0002 FOMUL .EQU $0004 FODIV .EQU $0006 FOCMP .EQU $0008 FOCPX .EQU $000A FOREM .EQU $000C FOZ2X .EQU $000E FOX2Z .EQU $0010 FOSQRT .EQU $0012 FORTI .EQU $0014 FOTTI .EQU $0016 FOSCALB .EQU $0018 FOLOGB .EQU $001A FOCLASS .EQU $001C ; UNDEFINED .EQU $001E FOSETENV .EQU $0001 FOGETENV .EQU $0003 FOSETTV .EQU $0005 FOGETTV .EQU $0007 FOD2B .EQU $0009 FOB2D .EQU $000B FONEG .EQU $000D FOABS .EQU $000F FOCPYSGNX .EQU $0011 FONEXT .EQU $0013 FOSETXCP .EQU $0015 FOPROCENTRY .EQU $0017 FOPROCEXIT .EQU $0019 FOTESTXCP .EQU $001B ; UNDEFINED .EQU $001D ; UNDEFINED .EQU $001F ;----------------------------------------------------------- ; OPERAND FORMAT MASKS: bits $3800 determine the format of ; any non-extended operand. ;----------------------------------------------------------- FFEXT .EQU $0000 ; extended -- 80-bit float FFDBL .EQU $0800 ; double -- 64-bit float FFSGL .EQU $1000 ; single -- 32-bit float FFINT .EQU $2000 ; integer -- 16-bit integer FFLNG .EQU $2800 ; long int -- 32-bit integer FFCOMP .EQU $3000 ; accounting -- 64-bit int ;----------------------------------------------------------- ; Bit indexes for error and halt bits and rounding modes in ; the state word. The word is broken down as: ; ; $8000 -- unused ; ; $6000 -- rounding modes ; $0000 -- to nearest ; $2000 -- toward +infinity ; $4000 -- toward -infinity ; $6000 -- toward zero ; ; $1F00 -- error flags ; $1000 -- inexact ; $0800 -- division by zero ; $0400 -- overflow ; $0200 -- underflow ; $0100 -- invalid operation ; ; $0080 -- result of last rounding ; $0000 -- rounded down in magnitude ; $0080 -- rounded up in magnitude ; ; $0060 -- precision control ; $0000 -- extended ; $0020 -- double ; $0040 -- single ; $0060 -- ILLEGAL ; ; $001F -- halt enables, corresponding to error flags ; ; The bit indexes are based on the byte halves of the state ; word. ;----------------------------------------------------------- FBINVALID .EQU 0 ; invalid operation FBUFLOW .EQU 1 ; underflow FBOFLOW .EQU 2 ; overflow FBDIVZER .EQU 3 ; division by zero FBINEXACT .EQU 4 ; inexact FBRNDLO .EQU 5 ; low bit of rounding mode FBRNDHI .EQU 6 ; high bit of rounding mode FBLSTRND .EQU 7 ; last round result bit FBDBL .EQU 5 ; double precision control FBSGL .EQU 6 ; single precision control ;----------------------------------------------------------- ; FLOATING CONDITIONAL BRANCHES: floating point comparisons ; set the CPU condition code register (the CCR) as follows: ; relation X N Z V C ; ------------------------- ; equal 0 0 1 0 0 ; less than 1 1 0 0 1 ; greater than 0 0 0 0 0 ; unordered 0 0 0 1 0 ; The macros below define a set of so-called floating ; branches to spare the programmer repeated refernces to the ; the table above. ;----------------------------------------------------------- (.MACRO FBEQ (BEQ %1 (.ENDM (.MACRO FBLT (BCS %1 (.ENDM (.MACRO FBLE (BLS %1 (.ENDM (.MACRO FBGT (BGT %1 (.ENDM (.MACRO FBGE (BGE %1 (.ENDM (.MACRO FBULT (BLT %1 (.ENDM (.MACRO FBULE (BLE %1 (.ENDM (.MACRO FBUGT (BHI %1 (.ENDM (.MACRO FBUGE (BCC %1 (.ENDM (.MACRO FBU (BVS %1 (.ENDM (.MACRO FBO (BVC %1 (.ENDM (.MACRO FBNE (BNE %1 (.ENDM (.MACRO FBUE (BEQ %1 (BVS %1 (.ENDM (.MACRO FBLG (BNE %1 (BVC %1 (.ENDM ; Short branch versions. (.MACRO FBEQS (BEQ.S %1 (.ENDM (.MACRO FBLTS (BCS.S %1 (.ENDM (.MACRO FBLES (BLS.S %1 (.ENDM (.MACRO FBGTS (BGT.S %1 (.ENDM (.MACRO FBGES (BGE.S %1 (.ENDM (.MACRO FBULTS (BLT.S %1 (.ENDM (.MACRO FBULES (BLE.S %1 (.ENDM (.MACRO FBUGTS (BHI.S %1 (.ENDM (.MACRO FBUGES (BCC.S %1 (.ENDM (.MACRO FBUS (BVS.S %1 (.ENDM (.MACRO FBOS (BVC.S %1 (.ENDM (.MACRO FBNES (BNE.S %1 (.ENDM (.MACRO FBUES (BEQ.S %1 (BVS.S %1 (.ENDM (.MACRO FBLGS (BNE.S %1 (BVC.S %1 (.ENDM ;----------------------------------------------------------- ; OPERATION MACROS: ; THESE MACROS REQUIRE THAT THE OPERANDS' ADDRESSES ; FIRST BE PUSHED ON THE STACK. THE MACROS CANNOT ; THEMSELVES PUSH THE ADDRESSES SINCE THE ADDRESSES ; MAY BE SP-RELATIVE, IN WHICH CASE THEY REQUIRE ; PROGRAMMER CARE. ; OPERATION MACROS: operand addresses should already be on ; the stack, with the destination address on top. The ; suffix X, D, S, or C determines the format of the source ; operand -- extended, double, single, or computational ; respectively; the destination operand is always extended. ;----------------------------------------------------------- ;----------------------------------------------------------- ; Addition. ;----------------------------------------------------------- (.MACRO FADDX (MOVE.W #FFEXT+FOADD,-(SP) (JSRFP (.ENDM (.MACRO FADDD (MOVE.W #FFDBL+FOADD,-(SP) (JSRFP (.ENDM (.MACRO FADDS (MOVE.W #FFSGL+FOADD,-(SP) (JSRFP (.ENDM (.MACRO FADDC (MOVE.W #FFCOMP+FOADD,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Subtraction. ;----------------------------------------------------------- (.MACRO FSUBX (MOVE.W #FFEXT+FOSUB,-(SP) (JSRFP (.ENDM (.MACRO FSUBD (MOVE.W #FFDBL+FOSUB,-(SP) (JSRFP (.ENDM (.MACRO FSUBS (MOVE.W #FFSGL+FOSUB,-(SP) (JSRFP (.ENDM (.MACRO FSUBC (MOVE.W #FFCOMP+FOSUB,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Multiplication. ;----------------------------------------------------------- (.MACRO FMULX (MOVE.W #FFEXT+FOMUL,-(SP) (JSRFP (.ENDM (.MACRO FMULD (MOVE.W #FFDBL+FOMUL,-(SP) (JSRFP (.ENDM (.MACRO FMULS (MOVE.W #FFSGL+FOMUL,-(SP) (JSRFP (.ENDM (.MACRO FMULC (MOVE.W #FFCOMP+FOMUL,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Division. ;----------------------------------------------------------- (.MACRO FDIVX (MOVE.W #FFEXT+FODIV,-(SP) (JSRFP (.ENDM (.MACRO FDIVD (MOVE.W #FFDBL+FODIV,-(SP) (JSRFP (.ENDM (.MACRO FDIVS (MOVE.W #FFSGL+FODIV,-(SP) (JSRFP (.ENDM (.MACRO FDIVC (MOVE.W #FFCOMP+FODIV,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Compare, signaling no exceptions. ;----------------------------------------------------------- (.MACRO FCMPX (MOVE.W #FFEXT+FOCMP,-(SP) (JSRFP (.ENDM (.MACRO FCMPD (MOVE.W #FFDBL+FOCMP,-(SP) (JSRFP (.ENDM (.MACRO FCMPS (MOVE.W #FFSGL+FOCMP,-(SP) (JSRFP (.ENDM (.MACRO FCMPC (MOVE.W #FFCOMP+FOCMP,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Compare, signaling invalid operation if the two operands ; are unordered. ;----------------------------------------------------------- (.MACRO FCPXX (MOVE.W #FFEXT+FOCPX,-(SP) (JSRFP (.ENDM (.MACRO FCPXD (MOVE.W #FFDBL+FOCPX,-(SP) (JSRFP (.ENDM (.MACRO FCPXS (MOVE.W #FFSGL+FOCPX,-(SP) (JSRFP (.ENDM (.MACRO FCPXC (MOVE.W #FFCOMP+FOCPX,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Remainder. The remainder is placed in the destination, ; and the low bits of the integer quotient are placed in ; the low word of register D0. ;----------------------------------------------------------- (.MACRO FREMX (MOVE.W #FFEXT+FOREM,-(SP) (JSRFP (.ENDM (.MACRO FREMD (MOVE.W #FFDBL+FOREM,-(SP) (JSRFP (.ENDM (.MACRO FREMS (MOVE.W #FFSGL+FOREM,-(SP) (JSRFP (.ENDM (.MACRO FREMC (MOVE.W #FFCOMP+FOREM,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Compare the source operand to the extended format and ; place in the destination. ;----------------------------------------------------------- (.MACRO FX2X (MOVE.W #FFEXT+FOZ2X,-(SP) (JSRFP (.ENDM (.MACRO FD2X (MOVE.W #FFDBL+FOZ2X,-(SP) (JSRFP (.ENDM (.MACRO FS2X (MOVE.W #FFSGL+FOZ2X,-(SP) (JSRFP (.ENDM (.MACRO FI2X ; 16-bit integer (MOVE.W #FFINT+FOZ2X,-(SP) (JSRFP (.ENDM (.MACRO FL2X ; 32-bit integer (MOVE.W #FFLNG+FOZ2X,-(SP) (JSRFP (.ENDM (.MACRO FC2X (MOVE.W #FFCOMP+FOZ2X,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Convert the extended source operand to the specified ; format and place in the destination. ;----------------------------------------------------------- (.MACRO FX2D (MOVE.W #FFDBL+FOX2Z,-(SP) (JSRFP (.ENDM (.MACRO FX2S (MOVE.W #FFSGL+FOX2Z,-(SP) (JSRFP (.ENDM (.MACRO FX2I ; 16-bit integer (MOVE.W #FFINT+FOX2Z,-(SP) (JSRFP (.ENDM (.MACRO FX2L ; 32-bit integer (MOVE.W #FFLNG+FOX2Z,-(SP) (JSRFP (.ENDM (.MACRO FX2C (MOVE.W #FFCOMP+FOX2Z,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Miscellaneous operations applying only to extended ; operands. The input operand is overwritten with the ; computed result. ;----------------------------------------------------------- ; Square root. (.MACRO FSQRTX (MOVE.W #FOSQRT,-(SP) (JSRFP (.ENDM ; Round to integer, according to the current rounding mode. (.MACRO FRINTX (MOVE.W #FORTI,-(SP) (JSRFP (.ENDM ; Round to integer, forcing rounding toward zero. (.MACRO FTINTX (MOVE.W #FOTTI,-(SP) (JSRFP (.ENDM ; Set the destination to the product: ; (destination) * 2^(source) ; where the source operand is a 16-bit integer. (.MACRO FSCALBX (MOVE.W #FFINT+FOSCALB,-(SP) (JSRFP (.ENDM ; Replace the destination with its exponent, converted to ; the extended format. (.MACRO FLOGBX (MOVE.W #FOLOGB,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Non-arithmetic sign operations on extended operands. ;----------------------------------------------------------- ; Negate. (.MACRO FNEGX (MOVE.W #FONEG,-(SP) (JSRFP (.ENDM ; Absolute value. (.MACRO FABSX (MOVE.W #FOABS,-(SP) (JSRFP (.ENDM ; Copy the sign of the destination operand onto the sign of ; the source operand. Note that the source operand is ; modified. (.MACRO FCPYSGNX (MOVE.W #FOCPYSGN,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; The nextafter operation replaces the source operand with ; its nearest representable neighbor in the direction of the ; destination operand. Note that both operands are of the ; the same format, as specified by the usual suffix. ;----------------------------------------------------------- (.MACRO FNEXTS (MOVE.W #FFSGL+FONEXT,-(SP) (JSRFP (.ENDM (.MACRO FNEXTD (MOVE.W #FFDBL+FONEXT,-(SP) (JSRFP (.ENDM (.MACRO FNEXTX (MOVE.W #FFEXT+FONEXT,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; The classify operation places an integer in the ; destination. The sign of the integer is the sign of the ; source. The magnitude is determined by the value of the ; source, as indicated by the equates. ;----------------------------------------------------------- FCSNAN .EQU 1 ; signaling NAN FCQNAN .EQU 2 ; quiet NAN FCINF .EQU 3 ; infinity FCZERO .EQU 4 ; zero FCNORM .EQU 5 ; normal number FCDENORM .EQU 6 ; denormal number (.MACRO FCLASSS (MOVE.W #FFSGL+FOCLASS,-(SP) (JSRFP (.ENDM (.MACRO FCLASSD (MOVE.W #FFDBL+FOCLASS,-(SP) (JSRFP (.ENDM (.MACRO FCLASSX (MOVE.W #FFEXT+FOCLASS,-(SP) (JSRFP (.ENDM (.MACRO FCLASSC (MOVE.W #FFCOMP+FOCLASS,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; These four operations give access to the floating point ; state (or environment) word and the halt vector address. ; The sole input operand is a pointer to the word or address ; to be placed into the arithmetic state area or read from ; it. ;----------------------------------------------------------- (.MACRO FGETENV (MOVE.W #FOGETENV,-(SP) (JSRFP (.ENDM (.MACRO FSETENV (MOVE.W #FOSETENV,-(SP) (JSRFP (.ENDM (.MACRO FGETTV (MOVE.W #FOGETTV,-(SP) (JSRFP (.ENDM (.MACRO FSETTV (MOVE.W #FOSETTV,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Both FPROCENTRY and FPROCEXIT have one operand -- a ; pointer to a word. The entry procedure saves the current ; floating point state in that word and resets the state ; to 0, that is all modes to default, flags and halts to ; OFF. The exit procedure performs the sequence: ; 1. Save current error flags in a temporary. ; 2. Restore the state saved at the address given by ; the parameter. ; 3. Signal the exceptions flagged in the temporary, ; halting if so specified by the newly ; restored state word. ; These routines serve to handle the state word dynamically ; across subroutine calls. ;----------------------------------------------------------- (.MACRO FPROCENTRY (MOVE.W #FOPROCENTRY,-(SP) (JSRFP (.ENDM (.MACRO FPROCEXIT (MOVE.W #FOPROCEXIT,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; FSETXCP is a null arithmetic operation which stimulates ; the indicated exception. It may be used by library ; routines intended to behave like elementary operations. ; The operand is a pointer to an integer taking any value ; between FBINVALID and FBINEXACT. ; FTESTXCP tests the flag indicated by the integer pointed ; to by the input address. The integer is replaced by a ; Pascal boolean (word $0000=false, $0100=true) ;----------------------------------------------------------- (.MACRO FSETXCP (MOVE.W #FOSETXCP,-(SP) (JSRFP (.ENDM (.MACRO FTESTXCP (MOVE.W #FOTESTXCP,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; WARNING: PASCAL ENUMERATED TYPES, LIKE THOSE OF THE ; DECIMAL RECORD, ARE STORED IN THE HIGH-ORDER BYTE OF THE ; ALLOCATED WORD, IF POSSIBLE. THUS THE SIGN HAS THE ; INTEGER VALUE 0 FOR PLUS AND 256 (RATHER THAN 1) ; FOR MINUS. ; BINARY-DECIMAL CONVERSION: The next routines convert ; between a canonical decimal format and the binary format ; specified. The decimal format is defined in Pascal as ; ; CONST ; SIGDIGLEN = 20; ; ; TYPE ; SigDig = string [SIGDIGLEN]; ; Decimal = record ; sgn : 0..1; ; exp : integer; ; sig : SigDig ; end; ; ; Note that Lisa Pascal stores the sgn in the high-order ; byte of the allotted word, so the two legal word values ; of sgn are 0 and 256. ;----------------------------------------------------------- ;----------------------------------------------------------- ; Decimal to binary conversion is governed by a format ; record defined in Pascal as: ; ; TYPE ; DecForm = record ; style : (FloatDecimal, FixedDecimal); ; digits : integer ; end; ; ; Note again that the style field is stored in the high- ; order byte of the allotted word. ; ; These are the only operations with three operands. The ; pointer to the format record is deepest in the stack, ; then the source pointer, and finally the destination ; pointer. ;----------------------------------------------------------- (.MACRO FDEC2X (MOVE.W #FFEXT+FOD2B,-(SP) (JSRFP (.ENDM (.MACRO FDEC2D (MOVE.W #FFDBL+FOD2B,-(SP) (JSRFP (.ENDM (.MACRO FDEC2S (MOVE.W #FFSGL+FOD2B,-(SP) (JSRFP (.ENDM (.MACRO FDEC2C (MOVE.W #FFCOMP+FOD2B,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Binary to decimal conversion. ;----------------------------------------------------------- (.MACRO FX2DEC (MOVE.W #FFEXT+FOB2D,-(SP) (JSRFP (.ENDM (.MACRO FD2DEC (MOVE.W #FFDBL+FOB2D,-(SP) (JSRFP (.ENDM (.MACRO FS2DEC (MOVE.W #FFSGL+FOB2D,-(SP) (JSRFP (.ENDM (.MACRO FC2DEC (MOVE.W #FFCOMP+FOB2D,-(SP) (JSRFP (.ENDM ;----------------------------------------------------------- ; Equates and macros for elementary functions. ;----------------------------------------------------------- FOLNX .EQU $0000 FOLOG2X .EQU $0002 FOLN1X .EQU $0004 FOLOG21X .EQU $0006 FOEXPX .EQU $0008 FOEXP2X .EQU $000A FOEXP1X .EQU $000C FOEXP21X .EQU $000E FOXPWRI .EQU $8010 FOXPWRY .EQU $8012 FOCOMPOUNDX .EQU $C014 FOANNUITYX .EQU $C016 FOSINX .EQU $0018 FOCOSX .EQU $001A FOTANX .EQU $001C FOATANX .EQU $001E FORANDOMX .EQU $0020 (.MACRO FLNX (MOVE.W #FOLNX,-(SP) (JSRELEMS (.ENDM (.MACRO FLOG2X (MOVE.W #FOLOG2X,-(SP) (JSRELEMS (.ENDM (.MACRO FLN1X (MOVE.W #FOLN1X,-(SP) (JSRELEMS (.ENDM (.MACRO FLOG21X (MOVE.W #FOLOG21X,-(SP) (JSRELEMS (.ENDM (.MACRO FEXPX (MOVE.W #FOEXPX,-(SP) (JSRELEMS (.ENDM (.MACRO FEXP2X (MOVE.W #FOEXP2X,-(SP) (JSRELEMS (.ENDM (.MACRO FEXP1X (MOVE.W #FOEXP1X,-(SP) (JSRELEMS (.ENDM (.MACRO FEXP21X (MOVE.W #FOEXP21X,-(SP) (JSRELEMS (.ENDM (.MACRO FXPWRI (MOVE.W #FOXPWRI,-(SP) (JSRELEMS (.ENDM (.MACRO FXPWRY (MOVE.W #FOXPWRY,-(SP) (JSRELEMS (.ENDM (.MACRO FCOMPOUNDX (MOVE.W #FOCOMPOUNDX,-(SP) (JSRELEMS (.ENDM (.MACRO FANNUITYX (MOVE.W #FOANNUITYX,-(SP) (JSRELEMS (.ENDM (.MACRO FSINX (MOVE.W #FOSINX,-(SP) (JSRELEMS (.ENDM (.MACRO FCOSX (MOVE.W #FOCOSX,-(SP) (JSRELEMS (.ENDM (.MACRO FTANX (MOVE.W #FOTANX,-(SP) (JSRELEMS (.ENDM (.MACRO FATANX (MOVE.W #FOATANX,-(SP) (JSRELEMS (.ENDM (.MACRO FRANDOMX (MOVE.W #FORANDOMX,-(SP) (JSRELEMS (.ENDM ;----------------------------------------------------------- ;----------------------------------------------------------- ;----------------------------------------------------------- ;----------------------------------------------------------- W^wƥd5P:H r^b}c8c8; File SYSEQU.TEXT - Macintosh system equates file. ;_______________________________________________________________________ ; ; ; WRITTEN BY: Bud Tribble 6-May-81 ; ; All system routines include this equate file. ; ; MODIFICATION HISTORY: ; ; Integrate Lisagraf -- alo 23-Dec-81 ; Configured for Alpha release (one heap) -- alo 5-Feb-82 ; Moved Lisagraf variables up to allow more room -- alo 10-Feb-82 ; Added system base date & time variables -- alo 13-Feb-82 ; Allowed 20 bytes for system parameter ram area -- alo 1-Mar-82 ; Added ptr for SYSOUTFIB,SYSINFIB,SYSREFNUM(macpaslib) ; -- alo 1-Apr-82 ; Added SCC hardware addresses; removed 6551 stuff; ; pulled MBSTATE and MBTICKS from kbd driver vars -- LAK 10-May-82 ; added SCC write reg 5 globals; clock-keyboard ; synchronization flags . . . -- LAK 27-May-82 ; got rid of VBL queue element "mode" word -- LAK 04-Jun-82 ; changed KEYREPCOUNT to KEYREPTIME; added ; procedural interface variables for key mapping -- LAK 07-Jun-82 ; updated for 512-dots -- LAK 26-Aug-82 ; changed VIA addresses for timing problem -- LAK 17-Sep-82 ; changed IWM addresses for better margin -- LAK 23-Sep-82 ; updated to 384 current version (0.5D) -- LAK 10-Oct-82 ; added FSInitDbg for Filler1 (sysinit, debug) -- LAK 19-Oct-82 ; added TagData field for twiggy driver -- LAK 01-Nov-82 ; added DrvInstalled field for twiggy driver; ; changed WarmCold to TwiggyVars -- LAK 02-Nov-82 ; removed DrvInstalled field; removed FIB pointers, ; and changed start of system heap; changed loader ; variable area -- LAK 18 Nov 82 ; added a compare string jump vector -- LAK 10 Dec 82 ; changed driver definitons, etc. -- LAK 17 Dec 82 ; added VIA equates -- LAK 03 Jan 83 ; added new i/o param blk equates for new fs -- LAK 17 Jan 83 ; added storage manager error codes -- LAK 04 Feb 83 ; add disk cal switch error code -- LAK 05 Feb 83 ; added keyboard task vector in $124 (KybdTask); ; broke error codes out into SysErr.Text ; added LoadTrap lomem var -- LAK 16 Feb 83 ; put dispatch table where macsbug globals used ; to be and moved down toolbox vars. -- LAK 18 Feb 83 ; Added DSAlertTab pointer -- AJH 29 Mar 83 ; Added BootDrive field -- AJH 04 Apr 83 ; Added PollStack, PollProc, DskErr, DskRtnAdr -- LAK 11 Apr 83 ; Added SonyVars,PWMBuf2 -- LAK 17 Apr 83 ; Changed screen, PWM address for 512K proto -- AJH 01 May 83 ; Added Resource def -- BJH 09 May 83 ; Added PWMValue -- LAK 09 May 83 ; Added Heap check hooks -- MPH 10 May 83 ; Changed SCC addresses (high bits on) -- LAK 25 May 83 ; Added DQFSID, ; Stretched KeyPadMap to 8 bytes -- LAK 01 Jun 83 ; Added Mask constant, changed Heap check hooks -- MPH 02 Jun 83 ; Added equates for MinStack, DefltStack for memory ; manager; moved UnitEntries equate to StartInit; ; added UnitNtryCnt lomem var instead. -- LAK 16 Jun 83 ; Added "NoQueue" bit definition -- AJH 23 Jun 83 ; Added "CurIOTrap" (replacing "Filler3" ) -- AJH 26 Jun 83 ; Added "forTwiggy" conditional assembly switch -- AJH 27 Jun 83 ; Cleaned up: changed unused vars to Fillerx equates; ; changed ARdCmd,AWrCmd,ACtlCmd,AStsCmd to match ; trap numbers . . . -- LAK 15 Jul 83 ; Added mmInOK for memory manager checking. -- LAK 24 Jul 83 ; Added mmDefFlags for memory manager zone init. -- LAK 31 Jul 83 ; Added DskVerify for disk driver verify/read flag ; in place of DskDump -- LAK 06 Aug 83 ; Removed DNeedsStorage equate (no longer used) -- LAK 08 Aug 83 ; Added Loader global definitions, no more SPBot -- AJH 11 Aug 83 ; Added IWM lomem variable . . . -- LAK 15 Aug 83 ; Added EvtBufCnt, JCrsrTask, moved FinderName -- LAK 17 Aug 83 ; Moved JCrsrTask to GrafEqu. -- LAK 18 Aug 83 ; Added scrap vars to $960 . -- SC 18 Aug 83 ; Added StkLowPt var for useful measurements. -- LAK 19 Aug 83 ; Added DoubleTime and CaretTime -- SC 19 Aug 83 ; Added SPClikCaret to parameter ram -- SC 19 Aug 83 ; Folded SPKbd stuff in parameter ram -- SC 19 Aug 83 ; Corrected ROM size counts (RomBSize, RomWSize) -- AJH 22 Aug 83 ; Added keyClick bit in parameter ram -- AJH 11 Sep 83 ; Added GrowZone handle/pointer warnings -- SC 12 Sep 83 ; Added Resource Manager equates -- BLH 22 Sep 83 ; Added 16 bytes of printing globals -- AJH 30 Sep 83 ; Added desk ornament message equates,changed events AJH 08 Oct 83 ; Added DQDrvSize -- LAK 02 Nov 83 ; Added equates for JGNEFilter, ScrDmpEnb, ScrDmpType LAK 09 Nov 83 ; Added ScreenRow -- AJH/WDA 10 Nov 83 ; Added equates for DSAlertRect, DSDrawProc, ; EjectNotify, CoreEditVars, QDExist, ; WWExist and JShell -- LAK 16 Nov 83 ; Added equate for AlarmState -- LAK 22 Nov 83 ; Added equate for InitApplZone notify proc -- LAK 06 Dec 83 ; Added equates for screen vertical, horiz res -- LAK 19 Dec 83 ; Added NeedsGoodBye -- AJH 03 Jan 84 ; Added SysVersion -- AJH 06 Jan 84 ; Added DSWndUpdate, SEvtEnb flags -- LAK 11 Jan 84 ; Added FontFlag for font manager bug fix -- AJH 12 Jan 84 ;______________________________________________________________________ ;_______________________________________________________________________ ; ; System Low Memory Layout ; ; 0000-00FF Exception Vectors defined by the hardware ; 0100-0340 System Communications Area ; 0340-03FF File System globals (172 bytes used) ; 0400-07FF system core routine/LisaGraf/ToolBox dispatch table ; 0800-08FF Mouse/Cursor low-memory globals ; 0900-097F more os stuff ; 0980-0AFF toolbox variables ; 0B00-XXXX Start of system heap ; ; Some other important system data structures are allocated on the heap ; ;_______________________________________________________________________ ; conditional assembly switch to select Twiggy or Sony forTwiggy .EQU 0 ;_______________________________________________________________________ ; ; System Constants ;_______________________________________________________________________ ; Device Equates ; note -- all screen and sound addresses are for the 512K Mac, ; which will also work for the 128K machine since the address ; space wraps ScreenLow .EQU $0007A700 ; top of screen screen address SoundLow .EQU $0007FD00 ; low sound buffer address PWMBuffer .EQU $0007FD01 ; PWM bytes are low bytes SndBufWLen .EQU $0172 ; sound/disk buffer word length OvlyRAM .EQU $00600000 ; low RAM address when overlay is on OvlyScreen .EQU $0067A700 ; top of screen with overlay ROMStart .EQU $00400000 ; starting address of ROM code ROMWSize .EQU $00008000 ; 32768 words in present ROM ROMBSize .EQU $00010000 ; 65536 bytes in present ROM MemLSize .EQU $00008000 ; memory contains 32K long words MemWSize .EQU $00010000 ; 64K words MemBSize .EQU $00020000 ; and 128K bytes LineLen .EQU $40 ; horizontal screen line has 64 bytes ; VIA (6522) ; Absolute Addresses VBase .EQU $EFE1FE ; base address AVBufB .EQU VBase ; buffer B AVBufA .EQU $EFFFFE ; buffer A AVBufM .EQU AVBufB ; buffer with mouse button bit AVIFR .EQU $EFFBFE ; interrupt flag register AVIER .EQU $EFFDFE ; interrupt enable register ; Offsets VBufB .EQU 512*0 ; BUFFER B VBufAH .EQU 512*1 ; buffer a (with handshake) [ Dont use! ] VDIRB .EQU 512*2 ; DIRECTION B VDIRA .EQU 512*3 ; DIRECTION A VT1C .EQU 512*4 ; TIMER 1 COUNTER (L.O.) VT1CH .EQU 512*5 ; timer 1 counter (high order) VT1L .EQU 512*6 ; TIMER 1 LATCH (L.O.) VT1LH .EQU 512*7 ; timer 1 latch (high order) VT2C .EQU 512*8 ; TIMER 2 LATCH (L.O.) VT2CH .EQU 512*9 ; timer 2 counter (high order) VSR .EQU 512*10 ; SHIFT REGISTER VACR .EQU 512*11 ; AUX. CONTROL REG. VPCR .EQU 512*12 ; PERIPH. CONTROL REG. VIFR .EQU 512*13 ; INT. FLAG REG. VIER .EQU 512*14 ; INT. ENABLE REG. VBufA .EQU 512*15 ; BUFFER A VBufD .EQU VBufA ; disk head select buffer ; Buffer A: VAOut .EQU $7F ; VBufA output bits VAInit .EQU $7B ; VBufA initial values med. volume VSound .EQU $07 ; sound volume bits VSndPg2 .EQU 3 ; select sound page 2 if 0 VOverlay .EQU 4 ; overlay bit (overlay when 1) VHeadSel .EQU 5 VPage2 .EQU 6 ; select video page 2 if 0 VSCCWrReq .EQU 7 ; SCC write/request line ; Buffer B: VBOut .EQU $87 ; VBufB output bits VBInit .EQU $07 ; VBufB initial values RTCData .EQU 0 RTCClk .EQU 1 RTCEnb .EQU 2 ; enabled when 0 VSW .EQU 3 ; mouse switch (0 when down) VX2 .EQU 4 ; mouse X level VY2 .EQU 5 ; mouse Y level VH4 .EQU 6 ; horizontal sync VSndEnb .EQU 7 ; /sound enable (reset when 1) ; note: CA1 = VSync ; CA2 = 1 sec clock ; CB1,CB2 are keyboard interface. ;_______________________________________________________________________ ; ; SCC SERIAL CHIP ADDRESSES SCCRBase .EQU $9FFFF8 ; SCC base read address SCCWBase .EQU $BFFFF9 ; SCC base write address AData .EQU 6 ; offset for A channel data ACtl .EQU 2 ; offset for A channel control BData .EQU 4 ; offset for B channel data BCtl .EQU 0 ; offset for B channel control SCCData .EQU 4 ; general offset for data from control SCCWrite .EQU $200001 ; general offset for write from read RxBF .EQU 0 ; SCC receive buffer full TxBE .EQU 2 ; SCC transmit buffer empty ;_______________________________________________________________________ ; ; DISK ADDRESS DBase .EQU $DFE1FF ; disk address base DPh0L .EQU DBase ; phase 0 low DPh0H .EQU $DFE3FF ; phase 0 high DMtrOff .EQU $DFF1FF ; IWM Motor off DMtrOn .EQU $DFF3FF ; IWM Motor on DiskQ6L .EQU $DFF9FF ; shift register DiskQ6H .EQU $DFFBFF DiskQ7L .EQU $DFFDFF DiskQ7H .EQU $DFFFFF Ph0L .EQU 512*0 ; disk address offsets from base Ph0H .EQU 512*1 Ph1L .EQU 512*2 Ph1H .EQU 512*3 Ph2L .EQU 512*4 Ph2H .EQU 512*5 Ph3L .EQU 512*6 Ph3H .EQU 512*7 MtrOff .EQU 512*8 MtrOn .EQU 512*9 IntDrive .EQU 512*10 ; enable internal drive address ExtDrive .EQU 512*11 ; enable external drive address Q6L .EQU 512*12 Q6H .EQU 512*13 Q7L .EQU 512*14 Q7H .EQU 512*15 ;_______________________________________________________________________ ; ; Interrupt Auto-vector and Exception Definitions ;_______________________________________________________________________ LINE1010 .EQU $28 ; 1010 emulator trap (system routines) LINE1111 .EQU $2C ; 1111 emulator trap (reserved) AUTOINT1 .EQU $64 ; level 1 auto-vector AUTOINT2 .EQU $68 ; level 2 auto-vector AUTOINT3 .EQU $6C ; level 3 auto-vector AUTOINT4 .EQU $70 ; level 4 auto-vector AUTOINT5 .EQU $74 ; level 5 auto-vector AUTOINT6 .EQU $78 ; level 6 auto-vector AUTOINT7 .EQU $7C ; level 7 auto-vector ;_______________________________________________________________________ ; ; SYSCOM Equates (System Communication Area) ;_______________________________________________________________________ SysCom .EQU $100 ; start of system communication area ; SYSTEM LOCATIONS MonkeyLives .EQU $100 ; monkey lives if >= 0 ScrVRes .EQU $102 ; screen vertical resolution (dots/inch) ScrHRes .EQU $104 ; screen horizontal resolution (dots/inch) ScreenRow .EQU $106 ; rowBytes of Mac screen MemTop .EQU $108 ; Ptr to top of memory BufPtr .EQU $10C ; Ptr to bottom of code buffer StkLowPt .EQU $110 ; Lowest stack as measured in VBL task HeapEnd .EQU $114 ; Ptr to end of heap TheZone .EQU $118 ; Ptr to current heap zone UTableBase .EQU $11C ; Ptr to unit I/O table MacJmp .EQU $120 ; Ptr to MACSBUG jumptable DskRtnAdr .EQU $124 ; temp for disk driver TwiggyVars .EQU $128 ; Ptr to twiggy driver locals DskVerify .EQU $12C ; used by sony driver for read/verify LoadTrap .EQU $12D ; set to non-zero to trap before pgm strt mmInOK .EQU $12E ; non-zero when initial mem mngr cks ok DskWr11 .EQU $12F ; try 1-1 disk writes when non-zero ApplLimit .EQU $130 ; SonyVars .EQU ApplLimit+4 ; pointer to 3-1/2 disk driver vars PWMValue .EQU SonyVars+4 ; current PWM value PollStack .EQU PWMValue+2 ; SCC poll data start stack location PollProc .EQU PollStack+4 ; proc which handles SCC poll data DskErr .EQU PollProc+4 ; disk routine result code SysEvtMask .EQU DskErr+2 ; System event mask SysEvtBuf .EQU SysEvtMask+2 ; Ptr to system event queue element buffer EventQueue .EQU SysEvtBuf+4 ; 5 words, event queue header EvtBufCnt .EQU EventQueue+10 ; max number of events in SysEvtBuf - 1 RndSeed .EQU EvtBufCnt+2 SysVersion .EQU RndSeed+4 ; version # of RAM-based system SEvtEnb .EQU SysVersion+2 ; 1 byte: 0 disables SysEvent calls from GNE DSWndUpdate .EQU SEvtEnb+1 ; 1 byte: 0 flags GNE to paintBehind DS AlertRect FontFlag .EQU DSWndUpdate+1 ; boolean for font manager bug Filler3 .EQU FontFlag+1 ; 1 byte of filler VBLQueue .EQU Filler3+1 ; 5 words, VBL queue header Ticks .EQU VBLQueue+10 ; Tick count, time since boot in 1/60 increments MBTicks .EQU Ticks+4 ; tick count when mouse button last changed MBState .EQU MBTicks+4 ; current mouse button state Tocks .EQU MBState+1 ; Lisa sub-tick count KeyMap .EQU MBState+2 ; 2 longs, a bitmap of the keyboard KeypadMap .EQU KeyMap+8 ; 1 long, a bitmap for numeric pad-18bits KeyLast .EQU KeypadMap+8 ; lo byte: ASCII for last valid keycode H; hi byte: last valid keycode H; these are 0 when no key is down KeyTime .EQU KeyLast+2 ; long tickcount when KEYLAST was rec'd KeyRepTime .EQU KeyTime+4 ; long tickcount when key was last repeated KeyThresh .EQU KeyRepTime+4 ; word containing threshold for repeat KeyRepThresh .EQU KeyThresh+2 ; word containing repeat speed Lvl1DT .EQU KeyRepThresh+2 ; Interrupt level 1 dispatch table Lvl2DT .EQU Lvl1DT+32 ; Interrupt level 2 dispatch table UnitNtryCnt .EQU Lvl2DT+32 ; count of entries in unit table VIA .EQU UnitNtryCnt+2 ; VIA base address (use low memory addresses) SCCRd .EQU VIA+4 ; SCC base read address (to save code space) SCCWr .EQU SCCRd+4 ; SCC base write address IWM .EQU SCCWr+4 ; IWM base address GetParam .EQU IWM+4 ; Parameter blk for reading sys parameter area SysParam .EQU GetParam+20 ; 20 bytes of system parameter area SPValid .EQU SysParam ; byte 1 = validation field ($A7) SPOdometer .EQU SPValid+1 ; 2-4 = odometer SPPortA .EQU SPOdometer+3 ; 5-6 = SCC port A configuration SPPortB .EQU SPPortA+2 ; 7-8 = SCC port B configuration SPAlarm .EQU SPPortB+2 ; 9-12 = alarm time SPFont .EQU SPAlarm+4 ; 13-14 = default font id SPKbd .EQU SPFont+2 ; 15 = kbd repeat thresh in 4/60ths(4) H; kbd repeat rates in 2/60ths(4) SPPrint .EQU SPKbd+1 ; 16 = print stuff SPVolCtl .EQU SPPrint+1 ; 17 = volume control (low 3 bits) SPClikCaret .EQU SPVolCtl+1 ; 18 = double time in 4/60ths(4) H; caret blink time in 4/60ths(4) SPMisc1 .EQU SPClikCaret+1 ; 19 = english/metric (1), H; extra (2), H; country code (5) SPMisc2 .EQU SPMisc1+1 ; 20 = paranoia level (1), mouse H; scaling(1), keyClick (1), boot H; disk (1), menu flash (2), help H; level (2) Time .EQU SysParam+20 ; clock time when last read (extrapolated) BootDrive .EQU Time+4 ; drive number of boot drive JShell .EQU Time+6 ; used by journaling shell . . . Filler3A .EQU JShell+2 ; used by standard file KbdVars .EQU Filler3A+2 ; Keyboard manager variables (4 bytes) JKybdTask .EQU KbdVars+4 ; keyboard VBL task hook KbdType .EQU JKybdTask+4 ; high byte holds keyboard model number AlarmState .EQU KbdType+1 ; Bit7=parity, Bit6=beeped, Bit0=1=enabled CurIOTrap .EQU KbdType+2 ; trap the caused current IO transaction DiskVars .EQU CurIOTrap+2 ; Disk driver variables (62 bytes) SdVolume .EQU DiskVars+62 ; Global volume control (1 byte) SdEnable .EQU SdVolume+1 ; byte to enable 4 voice engine SoundVars .EQU SdEnable+1 ; Sound driver variables (really only 20 bytes) SoundPtr .EQU SoundVars ;pointer to 4VE sound definition table SoundBase .EQU SoundPtr+4 ;base address of sound bitMap SoundVBL .EQU SoundBase+4 ;vertical retrace control element SoundDCE .EQU SoundVBL+16 ;pointer to sound driver DCE SoundActive .EQU SoundDCE+4 ;boolean specifying if sound is enabled SoundLevel .EQU SoundActive+1 ;byte specifying current level in buffer CurPitch .EQU SoundLevel+1 ;word holding current pitch value SoundLast .EQU CurPitch+2 ;address past last sound variable ScreenVars .EQU SoundVars+48 ; Screen driver variables JGNEFilter .EQU ScreenVars+8 ; GetNextEvent filter proc Key1Trans .EQU JGNEFilter+4 ; pointer to procedure handling keyboard H; key translation Key2Trans .EQU Key1Trans+4 ; pointer to procedure handling numeric H; keypad key translation SysZone .EQU Key2Trans+4 ; pointer to system heap zone ApplZone .EQU SysZone+4 ; pointer to application heap zone ROMBase .EQU ApplZone+4 ; start of ROM addresses (jump table?) RAMBase .EQU ROMBase+4 ; start of RAM addresses BasicGlob .EQU RAMBase+4 ; pointer to Basic globals DSAlertTab .EQU BasicGlob+4 ; pointer to deep shit alerts ExtStsDT .EQU DSAlertTab+4 ; SCC ext/sts secondary dispatch table SCCASts .EQU ExtStsDT+16 ; SCC read reg 0 last ext/sts rupt - A SCCBSts .EQU SCCASts+1 ; SCC read reg 0 last ext/sts rupt - B SerialVars .EQU SCCBSts+1 ; async driver variables FinderName .EQU SerialVars+16 ; 16 byte name of Finder doubleTime .EQU FinderName+16 ; double click time(Set up by boot blocks) caretTime .EQU doubleTime+4 ; caret blink time ScrDmpEnb .EQU caretTime+4 ; screen dump enabled when non-zero ScrDmpType .EQU ScrDmpEnb+1 ; FF dumps screen, FE dumps front window TagData .EQU ScrDmpType+1 ; sector tag info for twiggy drivers DrvQHdr .EQU TagData+14 ; queue header of drive numbers in system PWMBuf2 .EQU DrvQHdr+10 ; pointer to PWM buffer 1 (or 2 if sound H; buffer 2 is being used) HpChk .EQU PWMBuf2+4 ; Points to heap check RAM code MaskBC .EQU HpChk+4 ; Memory Manager Byte Count Mask MaskHandle .EQU MaskBC ; Memory Manager Handle Mask MaskPtr .EQU MaskBC ; Memory Manager Pointer Mask MinStack .EQU MaskBC+4 ; min stack size (1024) used in InitApplZone DefltStack .EQU MinStack+4 ; default size of stack (for growing AZone) mmDefFlags .EQU DefltStack+4 ; default zone flags GZRootHnd .EQU mmDefFlags+2 ; root handle for GrowZone GZRootPtr .EQU GZRootHnd+4 ; root pointer for GrowZone GZMoveHnd .EQU GZRootPtr+4 ; moving handle for GrowZone DSDrawProc .EQU GZMoveHnd+4 ; alternate deepshit box draw proc EjectNotify .EQU DSDrawProc+4 ; proc to call and notify upon ejects IAZNotify .EQU EjectNotify+4 ; proc to call and notify upon world swaps endofvars .EQU IAZNotify+4 ; end of final defined vars ;_______________________________________________________________________ ; ; The File System local variables are kept from $340 to $3FF ;_______________________________________________________________________ FileVars .EQU $340 ; DSAlertRect .EQU $3F8 ; rectangle for disk-switch alert ;_______________________________________________________________________ ; ; System Core Routine Dispatch Table resides from $400-$7FF. The user ; can intercept any core routine by changing these pointers. ;_______________________________________________________________________ DispatchTab .EQU $400 ;_______________________________________________________________________ ; ; The cursor jump table interface and cursor state variables start at $800 ; For their definitions, see the file "GRAFEQU.TEXT". Starting at $8FC and ; working down we have addresses of OS routines which are not accessed ; through traps. ;_______________________________________________________________________ WWExist .EQU $8F2 ; zero when window manager is initialized QDExist .EQU $8F3 ; zero when quickdraw is initialized JFetch .EQU $8F4 ; fetch a byte routine for I/O drivers JStash .EQU $8F8 ; stash a byte routine for I/O drivers JIODone .EQU $8FC ; IODone entry location LoadVars .EQU $900 ; loader variables ; low-memory Loader globals CurApRefNum .EQU LoadVars ; refNum of current resFile LaunchFlag .EQU CurApRefNum+2 ; boolean to distinguish launch/chain CurrentA5 .EQU LaunchFlag+2 ; current value of A5 CurStackBase .EQU CurrentA5+4 ; current stack base LoadFiller .EQU CurStackBase+4 ; empty for now... CurApName .EQU LoadFiller+4 ; place to save name of application SaveSegHandle .EQU CurApName+32 ; place to save seg 0 handle CurJTOffset .EQU SaveSegHandle+4 ; word for current jump table offset CurPageOption .EQU CurJTOffset+2 ; current page 2 configuration word LoaderPBlock .EQU CurPageOption+4 ; param block for internal ExitToShell LastLGlobal .EQU LoaderPBlock+10 ; address past last loader global PrintVars .EQU LastLGlobal ; 16 bytes for Owen LastPGlobal .EQU PrintVars+16 ; address of last global CoreEditVars .EQU LastPGlobal ; 12 bytes for core edit ; Low memory vars for the scrap manager scrapVars .EQU $960 scrapInfo .EQU scrapVars ; scrap info scrapHandle .EQU scrapInfo+4 ; handle to memory scrap scrapCount .EQU scrapHandle+4 ; validation byte scrapState .EQU scrapCount+2 ; state of scrap defined below scrapName .EQU scrapState+2 ; pointer to scrap name scrapTag .EQU scrapName+4 ; actual name goes here scrapEnd .EQU scrapTag+16 ; end of scrap vars ToolVars .EQU $980 ; toolbox variables ;_______________________________________________________________________ ; ; Finally, we have the start of the heap. Note that some important system ; tables are kept on the heap. ; ;_______________________________________________________________________ HeapStart .EQU $0B00 ; start of the heap ;_______________________________________________________________________ ; ; System Data Structures ; ;_______________________________________________________________________ Lock .EQU 7 ; lock bit in a master pointer Purge .EQU 6 ; bit for purgeable/unpurgeable Resource .EQU 5 ; bit to flag a resource handle ; Queue Header Definition QHeadSize .EQU 10 ; A queue header is 10 bytes long QFlags .EQU 0 ; misc. flags QHead .EQU 2 ; 32-bit ptr to first element QTail .EQU 6 ; 32-bit ptr to last element QInUse .EQU 7 ; queue-in-use flag bit ; Queue Element Type Definitions VType .EQU 1 ; VBL queue element is type 1 IOQType .EQU 2 ; I/O queue element is type 2 TimerType .EQU 3 ; timer queue element is type 3 EvType .EQU 4 ; event queue element is type 4 FSQType .EQU 5 ; File System VCB element ; General Purpose Queue Element Definition QLink .EQU 0 ; link to next queue element QType .EQU 4 ; queue element type ; Drive queue element offsets DQElLnth .EQU 12 ; drive queue element length including hdr ;change to 14 except for sony driver! DQDrive .EQU 6 ; drive number DQRefNum .EQU 8 ; driver refnum DQFSID .EQU 10 ; file system handling this drive DQDrvSize .EQU 12 ; number of blocks this drive ; Unit Table Definition -- there is one entry in the unit table for each ; logical driver. The number of entries is hardwired to 16. Each entry consists ; of one 32-bit memory handle; the first entry corresponds to RefNum -1, the ; last to RefNum -32. The Unit Table is made during sysInit time and is ; allocated from permanent system memory; lo-memory location UTableBase points ; to the table. UnitNtryCnt is initialized to UnitEntries by StartInit: all ; other code should use this low mem variable. ; Device Control Entry Definition: for each Unit Table Entry, one driver may be ; installed. If the driver is installed, the corresponding memory handle in the ; unit table will be the handle of a Device Control Entry. DCtlEntrySize .EQU 40 ; each entry is 40 bytes long DCtlDriver .EQU 0 ; offset of pointer to driver DCtlFlags .EQU 4 ; offset of flags word DCtlQueue .EQU 6 ; offset of queue header DCtlQHead .EQU 8 ; offset of queue first-element pointer DCtlQTail .EQU 12 ; offset of queue last-element pointer DCtlPosition .EQU 16 ; offset of longword position pointer DCtlStorage .EQU 20 ; handle of driver's private storage DCtlRefNum .EQU 24 ; refNum of this driver DCtlCurTicks .EQU 26 ; long counter for timing systemTask calls DCtlWindow .EQU 30 ; pointer to driver's window (if any) DCtlDelay .EQU 34 ; word for number of ticks between sysTask calls DCtlEMask .EQU 36 ; word for desk ornament event mask DCtlMenu .EQU 38 ; word for menu associated with driver ; Vertical Blanking Control Block Queue Element VBLINK .EQU 0 ; LINK TO NEXT ELEMENT VBLTYPE .EQU 4 ; UNIQUE ID FOR VALIDITY CHECK VBLADDR .EQU 6 ; ADDRESS OF SERVICE ROUTINE VBLCOUNT .EQU 10 ; COUNT FIELD FOR TIMEOUT VBLPHASE .EQU 12 ; PHASE TO ALLOW SYNCHRONIZATION ; INVBL .EQU 6 ; bit index for "in VBL" flag ; Driver Format Definitions DrvrFlags .EQU 0 ; various flags and permissions DrvrDelay .EQU 2 ; word indicating # of ticks between systask calls DrvrEMask .EQU 4 ; word indicating what events to accept DrvrMenu .EQU 6 ; word indicating driver menu ID DrvrOpen .EQU 8 ; word offset to open routine DrvrPrime .EQU 10 ; word offset to prime routine DrvrCtl .EQU 12 ; word offset to control routine DrvrStatus .EQU 14 ; word offset to status routine DrvrClose .EQU 16 ; word offset to warmstart reset routine DrvrName .EQU 18 ; length byte and name of driver ; Driver Flags Word Bit Field Definitions DReadEnable .EQU 0 ; driver enabled for read operations DWritEnable .EQU 1 ; driver enabled for writing DCtlEnable .EQU 2 ; driver enabled for control operations DStatEnable .EQU 3 ; driver enabled for status operations DNeedGoodBye .EQU 4 ; driver needs a "goodbye kiss" DNeedTime .EQU 5 ; driver needs "main thread" time DNeedLock .EQU 6 ; driver needs to be accessed at interrupt level ; Run-Time Flags (in DCtlFlags+1) DOpened .EQU 5 ; flag to mark driver 'Open' DRAMBased .EQU 6 ; 1=RAM-based Driver, 0=ROM-based DrvrActive .EQU 7 ; flag to mark the driver active ; Desk Ornament Message Definitions accEvent .EQU 64 ; feedEvent message accRun .EQU 65 ; SystemTask "run" message accCursor .EQU 66 ; cursor message for topMost window accMenu .EQU 67 ; menu message accCut .EQU 68 ; cut message from system edit accCopy .EQU 69 ; copy message from system edit accPaste .EQU 70 ; paste message from system edit accUndo .EQU 71 ; undo message from system edit accClear .EQU 72 ; clear message from system edit ; General system equates: IOQElSize .EQU 50 ; length of I/O parameter block IOLink .EQU 0 ; queue link in header IOType .EQU 4 ; type byte for safety check IOTrap .EQU 6 ; FS: the Trap IOCmdAddr .EQU 8 ; FS: address to dispatch to IOCompletion .EQU 12 ; long pointer to completion routine IOResult .EQU 16 ; IO result code (=D0 if sync call) IOFileName .EQU 18 ; file name pointer IOVRefNum .EQU 22 ; volume refnum IODrvNum .EQU IOVRefNum ; (used for Eject and MountVol) IORefNum .EQU 24 ; reference number for I/O operation IOFileType .EQU 26 ; specified along with FileName (byte) IOPermssn .EQU 27 ; Open: permissions (byte) IONewName .EQU 28 ; Rename: new name pointer (4) IOLEOF .EQU 28 ; GetEOF,SetEOF: logical end-of-file (4) IOOwnBuf .EQU 28 ; Open: optional ptr to locked 522-byte buffer IONewType .EQU 28 ; SetFileType: new type byte (1) IOBuffer .EQU 32 ; data buffer pointer IOByteCount .EQU 36 ; requested byte count IOReqCount .EQU 36 ; (equate used by file system Allocate) IONumDone .EQU 40 ; actual byte count completed IOActCount .EQU 40 ; (equate used by file system Allocate) IOPosMode .EQU 44 ; initial file positioning mode, eol char IOPosOffset .EQU 46 ; file position offset (long word) NoQueueBit .EQU 9 ; tells I/O system not to queue the request AsynTrpBit .EQU 10 ; bit in high byte of trap specifying async ; equates specific to GetFileInfo,SetFileInfo IOFQElSize .EQU 80 ; File command parameter block byte length @; 1st 28 bytes are the same as the general block IOFDirIndex .EQU 28 ; GetFileInfo - directory index IOFlAttrib .EQU 30 ; GetFileInfo - in-use bit=7, lock bit=0 IOFFlType .EQU 31 ; file type IOFlUsrWds .EQU 32 ; Get, SetFileInfo - user info (16 bytes) IOFFlNum .EQU 48 ; GetFileInfo - file number IOFlStBlk .EQU 52 ; GetFileInfo - Start file block (0000 if none) IOFlLgLen .EQU 54 ; File logical length (EOF) IOFlPyLen .EQU 58 ; File physical length in bytes. IOFlRStBlk .EQU 62 ; Start file block, resource fork (0000 if none) IOFlRLgLen .EQU 64 ; File logical length (EOF), resource fork IOFlRPyLen .EQU 68 ; File physical length, resource fork IOFlCrDat .EQU 72 ; File creation date & time (32 bits in seconds) IOFlMdDat .EQU 76 ; last modification date & time (32 bits in seconds) ; equates specific to GetVolInfo,GetVolume,SetVolume,MountVol,UnmountVol,Eject IOVQElSize .EQU 64 ; Volume command parameter block byte length IOVDrvNum .EQU IOVRefNum ; 1st 28 bytes are the same as the general block IOVNPtr .EQU IOFileName IOVolIndex .EQU 28 ; GetVol: volume index number IOVCrDate .EQU 30 ; GetVolInfo: creation date & time IOVLsBkUp .EQU 34 ; GetVolInfo: last backup date & time IOVAtrb .EQU 38 ; GetVolInfo: Volume attributes IOVNmFls .EQU 40 ; GetVolInfo: # files in directory IOVDirSt .EQU 42 ; GetVolInfo: start block of file dir IOVBlLn .EQU 44 ; GetVolInfo: length of dir in blocks IOVNmAlBlks .EQU 46 ; GetVolInfo: num blks (of alloc size) this dev IOVAlBlkSiz .EQU 48 ; GetVolInfo: alloc blk byte size IOVClpSiz .EQU 52 ; GetVolInfo: bytes to try to allocate at a time IOAlBlSt .EQU 56 ; starting diskette (512-byte) block in block map IOVNxtFNum .EQU 58 ; GetVolInfo: next free file number IOVFrBlk .EQU 62 ; GetVolInfo: word of # free alloc blks for this vol ; I/O Command Equates for I/O Queue Elements (match trap numbers) ARdCmd .EQU 2 ; read command AWrCmd .EQU 3 ; write command ACtlCmd .EQU 4 ; control command AStsCmd .EQU 5 ; status command ; special offsets for the control and status core routines CSCode .EQU 26 ; a word for the control/status code CSParam .EQU 28 ; operation-defined parameters (20-bytes max) ; System Event Definitions NullEvt .EQU 0 ; event 0 is the null event MButDwnEvt .EQU 1 ; mouse button down is event 1 MButUpEvt .EQU 2 ; mouse button up is event 2 KeyDwnEvt .EQU 3 ; key down is event 3 KeyUpEvt .EQU 4 ; key up is event 4 AutoKeyEvt .EQU 5 ; auto-repeated key is event 5 UpdatEvt .EQU 6 ; update event DiskInsertEvt .EQU 7 ; disk-inserted event ActivateEvt .EQU 8 ; activate/deactive event AbortEvt .EQU 9 ; abort? NetWorkEvt .EQU 10 ; network event ReserveEvt .EQU 10 ; reserved for system use IODrvrEvt .EQU 11 ; driver-defined event App1Evt .EQU 12 ; application defined events App2Evt .EQU 13 App3Evt .EQU 14 App4Evt .EQU 15 ; Event Record Definition EvtMax .EQU 30 ; maximum number of events in buffer EvtBlkSize .EQU 16 ; size in bytes of the event record EvtQBlkSize .EQU EvtBlkSize+6; size of event record counting queue info EvtNum .EQU 0 ; word containing ID number of event EvtMessage .EQU 2 ; longword containing event-defined msg EvtTicks .EQU 6 ; longword holding TICKS when event occured EvtMouse .EQU 10 ; longword holding mouse pos when event occured EvtMeta .EQU 14 ; byte containing meta key flags EvtMBut .EQU 15 ; byte indicating state of mouse button ; system device constants DskRfN .EQU $FFFB ; disk's reference number ; Control Call Codes EjectCode .EQU 7 ; control call eject code KillCode .EQU 1 ; KillIO code ; Status Call Codes DrvStsCode .EQU 8 ; status call code for drive status ; Resource Manager Equates ; High bits of the Locn long-word--the resource attributes: ; (Code optimization used frequently is a TST.B RAttr(A2) instead ; of BTST #ResSysRef, RAttr(A2). This saves a lot of bytes ; in RMgr) ResSysRef .EQU 7 ; reference to system/local reference ResSysHeap .EQU 6 ; In system/in application heap ResPurgeable .EQU 5 ; Purgeable/not purgeable ResLocked .EQU 4 ; Locked/not locked ResProtected .EQU 3 ; Protected/not protected ResPreload .EQU 2 ; Read in on openResource? ResChanged .EQU 1 ; Existing resource changed since last update ResUser .EQU 0 ; User defined resource attribute. ; When reading/writing, clear resChanged bit. RCBMask .EQU $FD ; ResChanged, byte mask AND. ; MAttr map attributes and masks MapReadOnly .EQU 7 ; is this file read-only? MapCompact .EQU 6 ; Is a compact necessary? MapChanged .EQU 5 ; Is it necessary to write map? MCCMask .EQU $60 ; MapCompact + MapChanged MChMask .EQU $20 ; MapChanged MCoMask .EQU $40 ; MapCompact 3. "6F^4P:H r^33Xÿ; File SysErr.Text - Macintosh system error equates file. ;_________________________________________________________________ ; ; ; All system routines reporting errors include this equate file. ; ; Modification History: ; 16 Feb 83 LAK Broke out from SysEqu.Text ; 22 Feb 83 LAK Added equates from SysUtil and Events. ; 10 May 83 MPH Added new memory manager error codes. ; 07 Jun 83 LAK Adjusted error codes for file system ; 15 Jun 83 AJH Added Deep Shit Error Definitions ; 23 Jun 83 LAK Added initIWMErr for sony driver. ; 18 Jul 83 LAK Added more memory manager deep shit errors. ; 11 Aug 83 LAK Added more disk driver error codes. ; 17 Aug 83 LAK Added file system deep shit error code. ; 18 Aug 83 SC Added scrap manager error codes. ; 19 Aug 83 LAK Added stackinheap deep shit code. ; 21 Aug 83 LAK Added SpdAdjErr, SeekErr, and SectNFErr for disk driver. ; Removed BadNybErr; moved clock/pram error codes up by 4. ; 23 Aug 83 LAK Added NotOpenErr for drivers. ; 27 Aug 83 AJH added memFull deep shit alert ; 06 Sep 83 AJH added DSBadLaunch ; 22 Sep 83 BLH Added Resource Mgr errors ; 10 Oct 83 LAK Added NoErr equate ; 13 Oct 83 LAK added NoErr, DSReInsert equates, DSNotThe1 ;_________________________________________________________________ ; General System Errors (VBL Mgr, Queueing, Etc.) NoErr .EQU 0 ; success is absence of errors QErr .EQU -1 ; queue element not found during deletion VTypErr .EQU -2 ; invalid queue element CorErr .EQU -3 ; core routine number out of range UnimpErr .EQU -4 ; unimplemented core routine ; I/O System Errors ControlErr .EQU -17 StatusErr .EQU -18 ReadErr .EQU -19 WritErr .EQU -20 BadUnitErr .EQU -21 UnitEmptyErr .EQU -22 OpenErr .EQU -23 ClosErr .EQU -24 DRemovErr .EQU -25 ; tried to remove an open driver DInstErr .EQU -26 ; DrvrInstall couldn't find driver in resources AbortErr .EQU -27 ; IO call aborted by KillIO NotOpenErr .EQU -28 ; Couldn't rd/wr/ctl/sts cause driver not opened ; File System error codes: DirFulErr .EQU -33 ; Directory full DskFulErr .EQU -34 ; disk full NSVErr .EQU -35 ; no such volume IOErr .EQU -36 ; I/O error (bummers) BdNamErr .EQU -37 ; there may be no bad names in the final system! FNOpnErr .EQU -38 ; File not open EOFErr .EQU -39 ; End of file PosErr .EQU -40 ; tried to position to before start of file (r/w) MFulErr .EQU -41 ; memory full(open) or file won't fit (load) TMFOErr .EQU -42 ; too many files open FNFErr .EQU -43 ; File not found WPrErr .EQU -44 ; diskette is write protected FLckdErr .EQU -45 ; file is locked VLckdErr .EQU -46 ; volume is locked FBsyErr .EQU -47 ; File is busy (delete) DupFNErr .EQU -48 ; duplicate filename (rename) OpWrErr .EQU -49 ; file already open with with write permission ParamErr .EQU -50 ; error in user parameter list RFNumErr .EQU -51 ; refnum error GFPErr .EQU -52 ; get file position error VolOffLinErr .EQU -53 ; volume not on line error (was Ejected) PermErr .EQU -54 ; permissions error (on file open) VolOnLinErr .EQU -55 ; drive volume already on-line at MountVol NSDrvErr .EQU -56 ; no such drive (tried to mount a bad drive num) NoMacDskErr .EQU -57 ; not a mac diskette (sig bytes are wrong) ExtFSErr .EQU -58 ; volume in question belongs to an external fs FSDSErr .EQU -59 ; file system deep s--t error: <; during rename the old entry was deleted but could <; not be restored . . . BadMDBErr .EQU -60 ; bad master directory block WrPermErr .EQU -61 ; write permissions error ; Disk, Serial Ports, Clock Specific Errors NoDriveErr .EQU -64 ; drive not installed OffLinErr .EQU -65 ; r/w requested for an off-line drive NoNybErr .EQU -66 ; couldn't find 5 nybbles in 200 tries NoAdrMkErr .EQU -67 ; couldn't find valid addr mark DataVerErr .EQU -68 ; read verify compare failed BadCkSmErr .EQU -69 ; addr mark checksum didn't check BadBtSlpErr .EQU -70 ; bad addr mark bit slip nibbles NoDtaMkErr .EQU -71 ; couldn't find a data mark header BadDCkSum .EQU -72 ; bad data mark checksum BadDBtSlp .EQU -73 ; bad data mark bit slip nibbles WrUnderRun .EQU -74 ; write underrun occurred CantStepErr .EQU -75 ; step handshake failed Tk0BadErr .EQU -76 ; track 0 detect doesn't change InitIWMErr .EQU -77 ; unable to initialize IWM TwoSideErr .EQU -78 ; tried to read 2nd side on a 1-sided drive SpdAdjErr .EQU -79 ; unable to correctly adjust disk speed SeekErr .EQU -80 ; track number wrong on address mark SectNFErr .EQU -81 ; sector number never found on a track ClkRdErr .EQU -85 ; unable to read same clock value twice ClkWrErr .EQU -86 ; time written did not verify PRWrErr .EQU -87 ; parameter ram written didn't read-verify PRInitErr .EQU -88 ; InitUtil found the parameter ram uninitialized RcvrErr .EQU -89 ; SCC receiver error (framing, parity, OR) BreakRecd .EQU -90 ; Break received (SCC) ; Storage allocator error codes MemFullErr .EQU -108 ; Not enough room in heap zone NilHandleErr .EQU -109 ; Handle was NIL in HandleZone or other; memWZErr .EQU -111 ; WhichZone failed (applied to free block); memPurErr .EQU -112 ; trying to purge a locked or non-purgable block; memAdrErr .EQU -110 ; address was odd, or out of range; memAZErr .EQU -113 ; Address in zone check failed; memPCErr .EQU -114 ; Pointer Check failed; memBCErr .EQU -115 ; Block Check failed; memSCErr .EQU -116 ; Size Check failed; ; Resource Manager error codes (other than I/O errors) ResNotFound .EQU -192 ; Resource not found ResFNotFound .EQU -193 ; Resource file not found AddResFailed .EQU -194 ; AddResource failed AddRefFailed .EQU -195 ; AddReference failed RmvResFailed .EQU -196 ; RmveResource failed RmvRefFailed .EQU -197 ; RmveReference failed ; Scrap Manager error codes noScrapErr .EQU -100 ; No scrap exists error noTypeErr .EQU -102 ; No object of that type in scrap ; Application Error Codes ; ; errors -1024 to -4095 are reserved for use by the current application ; Deep Shit Alert ID definitions DSSysErr .EQU 32767 ; general system error DSBusError .EQU 1 ; bus error DSAddressErr .EQU 2 ; address error DSIllInstErr .EQU 3 ; illegal instruction error DSZeroDivErr .EQU 4 ; zero divide error DSChkErr .EQU 5 ; check trap error DSOvFlowErr .EQU 6 ; overflow trap error DSPrivErr .EQU 7 ; privelege violation error DSTraceErr .EQU 8 ; trace mode error DSLineAErr .EQU 9 ; line 1010 trap error DSLineFErr .EQU 10 ; line 1111 trap error DSMiscErr .EQU 11 ; miscellaneous hardware exception error DSCoreErr .EQU 12 ; unimplemented core routine error DSIrqErr .EQU 13 ; uninstalled interrupt error DSIOCoreErr .EQU 14 ; IO Core Error DSLoadErr .EQU 15 ; Segment Loader Error DSFPErr .EQU 16 ; Floating point error DSNoPackErr .EQU 17 ; package 0 not present DSNoPk1 .EQU 18 ; package 1 not present DSNoPk2 .EQU 19 ; package 2 not present DSNoPk3 .EQU 20 ; package 3 not present DSNoPk4 .EQU 21 ; package 4 not present DSNoPk5 .EQU 22 ; package 5 not present DSNoPk6 .EQU 23 ; package 6 not present DSNoPk7 .EQU 24 ; package 7 not present DSMemFullErr .EQU 25 ; out of memory! DSBadLaunch .EQU 26 ; can't launch file DSStknHeap .EQU 28 ; stack has moved into application heap DSFSErr .EQU 27 ; file system map has been trashed DSReInsert .EQU 30 ; request user to reinsert off-line volume DSNotThe1 .EQU 31 ; not the disk I wanted ; Storage allocator trouble codes (deep shit IDs) MemTrbBase .EQU 32 ; Memory Manager Trouble Code base. mtSetLog .EQU MemTrbBase ; Set Logical Size Error. mtAdjFre .EQU MemTrbBase+1 ; Adjust Free Error. mtAdjCnt .EQU MemTrbBase+2 ; Adjust Counters Error. mtMkeBkf .EQU MemTrbBase+3 ; Make Block Free Error. mtSetSiz .EQU MemTrbBase+4 ; Set Size Error. mtInitMem .EQU MemTrbBase+5 ; Initialize Memory Manager Error. mtBCerr .EQU MemTrbBase+6 ; mtCZerr .EQU MemTrbBase+7 ; mtCZ1err .EQU MemTrbBase+8 ; mtCZ2err .EQU MemTrbBase+9 ; mtCZ3err .EQU MemTrbBase+10 ; mtEqCerr .EQU MemTrbBase+11 ; mtEvCerr .EQU MemTrbBase+12 ; mtHCerr .EQU MemTrbBase+13 ; mtPCerr .EQU MemTrbBase+14 ; mtSCerr .EQU MemTrbBase+15 ; mtRC1err .EQU MemTrbBase+16 ; mtRC2err .EQU MemTrbBase+17 ; mtSABerr .EQU MemTrbBase+18 ; mtACerr .EQU MemTrbBase+19 ; mtIZCerr .EQU MemTrbBase+20 ; mtPrCerr .EQU MemTrbBase+21 ; ; some miscellaneous result codes EvtNotEnb .EQU 1 ; event not enabled at PostEvent NoEvtAvail .EQU -1 ; no event available (GetOSEvent,OSEventAvail) W^x4PH r^r{%{%X҂; File: SysMacs.Text ;_______________________________________________________________________ ; ; SysMacs.Text - System macros include file. All system components ; should include this file of standard system macros. ; ; Written by: Bud Tribble 28-Oct-81 ; ; Modification History: ; ; AJH 30-Oct-81 - changed MOVE.L to LEA in "__CORE" macro ; AJH 02-Nov-81 - deleted SEEK and old memory management macros ; AJH 15-Nov-81 - added ASYNC option ; alo 2-Feb-82 - added some utility core routines ; LAK 05-Sep-82 - added DrvrInstall, DrvrRemove ; LAK 07-Sep-82 - added 5 object manager core routines ; MPH 29-Oct-82 - added System/Current option to mem man. macros. ; LAK 23 Dec 82 - removed object manager calls; added new file system ; traps (_UnMountVol,_MountVol,_FlushVol,_FlushFile, ; _OpenRF) and options (FilNam,FilNum); ; removed file system traps _ReadLabel,_WriteLabel. ; LAK 12 Jan 83 added CmpString, GetTrapAddr, SetTrapAddr macros ; LAK 18 Jan 83 added SetFilLock, RstFilLock, SetFilType macros ; LAK 21 Jan 83 made consistent with Andy's SysMacs ; MPH 2 Feb 83 reorganized macros to add new memory manager calls, ; remove SetHLock, SetHPurge ; LAK 4 Feb 83 added Delay (again) and AddDrive macros. Changed ; Exit to LoadFile. ; LAK 9 Feb 83 added SetGrowZone, CompactMem, PurgeMem ; LAK 10 Feb 83 added RDrvrInstall ; LAK 22 Feb 83 trap 63 is now InitUtil. ; AJH 12 Apr 83 Added REGS to GetTrapAddr ; LAK 03 Jun 83 Removed NOSAVE option (no longer used); added SetAppBase. ; LAK 16 Jun 83 Fixed macros for FreeMem, MaxMem, DisposPtr, SetPtrSize, ; GetPtrSize, DisposHandle, SetHandleSize, GetHandleSize, ; ReAllocHandle, EmptyHandle, SetApplLimit, HeapValidate, ; CompactMem, and PurgeMem to reflect correct options, reg save. ; SC 23 Jun 83 Added IMMED option for control calls. ; LAK 06 Aug 83 Added ResrvMem trap in place of HeapValidate; CompactMem, ; FreeMem, PurgeMem, and MaxMem traps adjusted for ,SYS ; option. ; LAK 12 Aug 83 Added ,CLEAR option for memory manager; added ,CASE and ; ,MARKS for string compares. ; LAK 11 Sep 83 Made CompactMem, FreeMem, PurgeMem, and ResrvMem use SAVE ; instead of REGS. ; LAK 16 Nov 83 Added OffLine trap for file system. ; LAK 30 Nov 83 Added MoreMasters call for memory manager. ;_______________________________________________________________________ ; Misc. system macros 0.MACRO __CORE 0.IF '%1' <> '' 0LEA %1,A0 0.ENDC 0.IF '%3' = '' 0.WORD $A000+%2 0.ENDC 0.IF '%3' = 'REGS' 0.WORD $A100+%2 0.ENDC 0.IF '%3' = 'ASYNC' 0.WORD $A400+%2 0.ENDC 0.IF '%3' = 'SYS' 0.WORD $A400+%2 0.ENDC 0.IF '%3' = 'IMMED' 0.WORD $A200+%2 0.ENDC 0.ENDM 0.MACRO __MCore 0.IF '%1' <> '' 0LEA %1,A0 0.ENDC 0.IF '%3' = '' 0.WORD $A000+%2 0.ENDC 0.IF '%3' = 'SAVE' 8.IF '%4' = 'SYS' @.WORD $A400+%2 @.ELSE @.WORD $A000+%2 8.ENDC 0.ENDC 0.IF '%3' = 'REGS' 8.IF '%4' = 'SYS' @.IF '%5' = 'CLEAR' @.WORD $A700+%2 @.ELSE @.WORD $A500+%2 @.ENDC 8.ELSE @.IF '%4' = 'CLEAR' @.WORD $A300+%2 @.ELSE @.WORD $A100+%2 @.ENDC 8.ENDC 0.ENDC 0.ENDM ; ; International string comparisons have two boolean parameters: ; bit 9 = 0 if and only if diacritical marks are significant ; bit 10 = 0 if and only if case is insignificant ; 0.MACRO __StrCore 0.IF '%1' <> '' 8LEA %1,A0 0.ENDC 0.IF '%3' = '' 8.WORD $A000+%2 0.ENDC 0.IF '%3' = 'MARKS' 8.IF '%4' = 'CASE' @.WORD $A600+%2 8.ELSE @.WORD $A200+%2 8.ENDC 0.ENDC 0.IF '%3' = 'CASE' 8.WORD $A400+%2 0.ENDC 0.ENDM ;_______________________________________________________________________ ; ; Core routine system macros ; ;_______________________________________________________________________ ; First we have the I/O core routine macros. These are also used by ; the file system. 0.MACRO _Open 0__CORE %1,0,%2 0.ENDM 0.MACRO _Close 0__CORE %1,1,%2 0.ENDM 0.MACRO _Read 0__CORE %1,2,%2 0.ENDM 0.MACRO _Write 0__CORE %1,3,%2 0.ENDM 0.MACRO _Control 0__CORE %1,4,%2 0.ENDM 0.MACRO _Status 0__CORE %1,5,%2 0.ENDM 0.MACRO _KillIO 0__CORE %1,6,%2 0.ENDM ; other file system calls go here 0.MACRO _GetVolInfo 0__CORE %1,7,%2 0.ENDM 0.MACRO _Create 0__CORE %1,8,%2 0.ENDM 0.MACRO _Delete 0__CORE %1,9,%2 0.ENDM 0.MACRO _OpenRF 0__CORE %1,10,%2 0.ENDM 0.MACRO _ReName 0__CORE %1,11,%2 0.ENDM 0.MACRO _GetFileInfo 0__CORE %1,12,%2 0.ENDM 0.MACRO _SetFileInfo 0__CORE %1,13,%2 0.ENDM 0.MACRO _UnMountVol 0__CORE %1,14 0.ENDM 0.MACRO _MountVol 0__CORE %1,15 0.ENDM 0.MACRO _Allocate 0__CORE %1,16,%2 0.ENDM 0.MACRO _GetEOF 0__CORE %1,17,%2 0.ENDM 0.MACRO _SetEOF 0__CORE %1,18,%2 0.ENDM 0.MACRO _FlushVol 0__CORE %1,19,%2 0.ENDM 0.MACRO _GetVol 0__CORE %1,20,%2 0.ENDM 0.MACRO _SetVol 0__CORE %1,21,%2 0.ENDM 0.MACRO _InitQueue 0__CORE %1,22 0.ENDM 0.MACRO _Eject 0__CORE %1,23,%2 0.ENDM 0.MACRO _GetFPos 0__CORE %1,24,%2 0.ENDM ; Here are the storage manager core routine macros 0.MACRO _InitZone 0__CORE %1,25 0.ENDM 0.MACRO _GetZone 0__CORE %1,26,REGS 0.ENDM 0.MACRO _SetZone 0__CORE %1,27 0.ENDM 0.MACRO _FreeMem 0__MCORE %1,28,SAVE,%2 0.ENDM 0.MACRO _MaxMem 0__MCORE %1,29,REGS,%2 0.ENDM 0.MACRO _NewPtr 0__MCORE %1,30,REGS,%2,%3 0.ENDM 0.MACRO _DisposPtr 0__CORE %1,31 0.ENDM 0.MACRO _SetPtrSize 0__CORE %1,32 0.ENDM 0.MACRO _GetPtrSize 0__CORE %1,33 0.ENDM 0.MACRO _NewHandle 0__MCORE %1,34,REGS,%2,%3 0.ENDM 0.MACRO _DisposHandle 0__CORE %1,35 0.ENDM 0.MACRO _SetHandleSize 0__CORE %1,36 0.ENDM 0.MACRO _GetHandleSize 0__CORE %1,37 0.ENDM 0.MACRO _HandleZone 0__CORE %1,38,REGS 0.ENDM 0.MACRO _ReAllocHandle 0__CORE %1,39 0.ENDM 0.MACRO _RecoverHandle 0__MCORE %1,40,REGS,%2,%3 0.ENDM 0.MACRO _HLock 0__CORE %1,41 0.ENDM 0.MACRO _HUnLock 0__CORE %1,42 0.ENDM 0.MACRO _EmptyHandle 0__CORE %1,43 0.ENDM 0.MACRO _InitApplZone 0__CORE %1,44 0.ENDM 0.MACRO _SetApplLimit 0__CORE %1,45 0.ENDM 0.MACRO _BlockMove 0__CORE %1,46 0.ENDM ; Here are the event manager macros 0.MACRO _PostEvent 0__CORE %1,47 0.ENDM 0.MACRO _OSEventAvail 0__CORE %1,48 0.ENDM 0.MACRO _GetOSEvent 0__CORE %1,49 0.ENDM 0.MACRO _FlushEvents 0__CORE %1,50 0.ENDM ; Here are the utility core routine macros 0.MACRO _VInstall 0__CORE %1,51 0.ENDM 0.MACRO _VRemove 0__CORE %1,52 0.ENDM 0.MACRO _Offline 0__CORE %1,53,%2 0.ENDM 0.MACRO _MoreMasters 0__CORE %1,54 0.ENDM 0.MACRO _ReadParam 0__CORE %1,55 0.ENDM 0.MACRO _WriteParam 0__CORE %1,56 0.ENDM 0.MACRO _ReadDateTime 0__CORE %1,57 0.ENDM 0.MACRO _SetDateTime 0__CORE %1,58 0.ENDM 0.MACRO _Delay 0__CORE %1,59 0.ENDM 0.MACRO _CmpString 0__StrCore %1,60 0.ENDM 0.MACRO _DrvrInstall 0__CORE %1,61 0.ENDM 0.MACRO _DrvrRemove 0__CORE %1,62 0.ENDM 0.MACRO _InitUtil 0__CORE %1,63 0.ENDM 0.MACRO _ResrvMem 0__MCORE %1,64,SAVE,%2 0.ENDM 0.MACRO _SetFilLock 0__CORE %1,65,%2 0.ENDM 0.MACRO _RstFilLock 0__CORE %1,66,%2 0.ENDM 0.MACRO _SetFilType 0__CORE %1,67,%2 0.ENDM 0.MACRO _SetFPos 0__CORE %1,68,%2 0.ENDM 0.MACRO _FlushFil 0__CORE %1,69,%2 0.ENDM 0.MACRO _GetTrapAddress 0__CORE %1,70,REGS 0.ENDM 0.MACRO _SetTrapAddress 0__CORE %1,71 0.ENDM 0.MACRO _PtrZone 0__CORE %1,72,REGS 0.ENDM 0.MACRO _HPurge 0__CORE %1,73 0.ENDM 0.MACRO _HNoPurge 0__CORE %1,74 0.ENDM 0.MACRO _SetGrowZone 0__CORE %1,75 0.ENDM 0.MACRO _CompactMem 0__MCORE %1,76,SAVE,%2 0.ENDM 0.MACRO _PurgeMem 0__MCORE %1,77,SAVE,%2 0.ENDM 0.MACRO _AddDrive 0__CORE %1,78 0.ENDM 0.MACRO _RDrvrInstall 0__CORE %1,79 0.ENDM 0.MACRO _UprString 0__StrCore %1,84 0.ENDM 0.MACRO _SetAppBase 0__CORE %1,87 0.ENDM 3. "6F^4D!$ǐ^9`9;;File TOOLEQU.TEXT ;-------------------------------------------------------------------------------- ; ; User Interface ToolBox Equate File ; ; This file contains global variable and data structure ; definitions for the MacIntosh User Interface ToolBox. ; It is included with all toolBox source files and ; possibly with some application programs. ; ; written by Andy Hertzfeld May 5, 1982 ; ; MODIFICATION HISTORY: ; ; AJH 23-May-82 Added window stuff ; AJH 22-Jun-82 Added icon stuff ; AJH 27-Jun-82 Added menu stuff ; AJH 31-Jul-82 Added control stuff; changed menu data structures ; AJH 10-Aug-82 Got rid of scrapWindow ; AJH 29-Aug-82 Added DragPattern,IShapeHook to globals, dragMsg to controls ; AJH 06-Sep-82 Added growWindow message ; AJH 12-Sep-82 Got rid of Alert and Dialog Window; added OneOne, MinusOne ; AJH 14-Sep-82 Changed for new font manager ; AJH 20-Sep-82 Added "goAway" boolean to windows; added symbolPtr globals ; BLH 24-Sep-82 Added alert, dialog globals and data structures ; AJH 05-Oct-82 Added ContrlAction field to control data structure ; BLH 7-Oct-82 Added indirect globals--took main globals out of low mem ; AJH 12-Oct-82 Switched over to new font manager globals; grafport now 64 bytes ; AJH 16-Nov-82 Added TaskLock for desk manager ; AJH 21-Nov-82 LGlobals,GPortSize change for ROM 1.8 ; BLH 17-Dec-82 Changed Dialog, Resource constants and globals ; BLH 19-Dec-82 Changed names for Resource upheaval ; AJH 19-Dec-82 Added CurActive,CurDeactive,deskHook globals ; AJH 24-Dec-82 Made defProcs defHandles, other data structure changes ; AJH 28-Dec-82 Broke off resource type and ID defs into separate file ; AJH 05-Jan-83 moved global base to $E80; put dialog stuff at end ; AJH 24-Jan-83 replaced MICONLIST with MBARENABLE ; BLH 5-Feb-83 Removed alertWindow, DialogWindow globals. Changed ; Dialog data structure defs. ; AJH 5-Feb-83 added MicroSoft bytes, other changes ; AJH 6-Feb-83 globals for scaling font manager ; AJH 12-Feb-83 got rid of checkFlag, made curDragAction 4 bytes long ; AJH 6-Mar-83 added GotStrike field for fontMgr (used byte from defSize) ; AJH 7-Mar-83 added scaleDisable ; AJH 5-Apr-83 added GhostWindow field in MicroSoft globals ; BLH 20-Apr-83 Changed alert and dialog templates. Removed AlertKind. ; SC 20-Apr-83 Added journal stuff at end ; SC 09-May-83 Added text edit defs, changed dialogs ; AJH 10-May-83 Added CloseOrnHook, FPAddress ; AJH 25-May-83 Added AppPacks table ; AJH 31-May-83 Changed size of grafPort for new QuickDraw, Added SysResName ; AJH 02-Jun-83 Changed PicScrap to theScrap ; AJH 08-Jun-83 Added AppParmHandle ; AJH 14-Jun-83 Added DSErrCode ; SC 23-Jun-83 Removed systemKind (it's now any negative number) ; AJH 05-Jul-83 Made it match the documentation ; SC 05-Aug-83 New TE record ; AJH 05-Aug-83 Added WGIconMsg to window defProc messages ; BLH 06-Aug-83 Added ResErrProc at end of tool globals. Made LastMap ; a temporary filler. ; SC 15-Aug-83 Dropped scrapInfo, theScrap ; AJH 28-Aug-83 Changed AppleMark, CheckMark to final values ; AJH 29-Aug-83 added "trackCtl" message ; BLH 6-Sep-83 added ResReadOnly global, replacing RFiller. ; SC 9-Sep-83 added teWdBreak for european stuff. ; AJH 12-Sep-83 added CurDeKind ; ;----------------------------------------------------------------------------------- ; ; Important Constants ; SCREENWIDTH .EQU 512 SCREENHEIGHT .EQU 342 SCREENRADIUS .EQU $00100010 ;rounded corners for desk area GPORTSIZE .EQU 108 ;a grafPort is 108 bytes ; ;------------------------------------------------------------ ; ; ToolBox Global Variables (kept in low memory) ; ; This section contains global variables for the font manager, ; the window manager and the menu manager ; ;------------------------------------------------------------ TOOLGBASE .EQU $980 ;ToolVars ;base address of toolbox globals LGLOBALS .EQU 0 ;QuickDraw globals accessed 0(A5) ;---------------------------- ; ; Font Manager Globals ; ;---------------------------- ; RomFont0 .EQU ToolGBase ;handle to ROM-based system font ApFontID .EQU RomFont0+4 ;family ID of standard application font GotStrike .EQU ApFontID+2 ;boolean indicating if we've got the strike FMDefaultSize .EQU GotStrike+1 ;byte holding default size CurFMInput .EQU FMDefaultSize+1 ;QuickDraw FMInput Record CurFMFamily .EQU CurFMInput ;current font family CurFMSize .EQU CurFMFamily+2 ;current font size CurFMFace .EQU CurFMSize+2 ;current font face CurFMNeedBits .EQU CurFMFace+1 ;boolean specifying whether it needs strike CurFMDevice .EQU CurFMNeedBits+1 ;current font device CurFMNumer .EQU CurFMDevice+2 ;current numerator of scale factor CurFMDenom .EQU CurFMNumer+4 ;current denominator of scale factor FMgrOutRec .EQU CurFMDenom+4 ;QuickDraw FontOutput Record FOutError .EQU FMgrOutRec ;error code FOutFontHandle .EQU FOutError+2 ;handle to font bits FOutBold .EQU FOutFontHandle+4 ;bolding factor FOutItalic .EQU FOutBold+1 ;italic factor FOutULOffset .EQU FOutItalic+1 ;underline offset FOutULShadow .EQU FOutULOffset+1 ;underline halo FOutULThick .EQU FOutULShadow+1 ;underline thickness FOutShadow .EQU FOutULThick+1 ;shadow factor FOutExtra .EQU FOutShadow+1 ;extra horizontal width FOutAscent .EQU FOutExtra+1 ;height above baseline FOutDescent .EQU FOutAscent+1 ;height below baseline FOutWidMax .EQU FOutDescent+1 ;maximum width of character FOutLeading .EQU FOutWidMax+1 ;space between lines FOutUnused .EQU FOutLeading+1 ;unused byte (must have even number) FOutNumer .EQU FOutUnused+1 ;point for numerators of scale factor FOutDenom .EQU FOutNumer+4 ;point for denominators of scale factor FMDotsPerInch .EQU FOutDenom+4 ;h,v dotsPerInch of current device FMStyleTab .EQU FMDotsPerInch+4 ;style heuristic table supplied by device ToolScratch .EQU FMStyleTab+24 ;8 byte scratch area ;---------------------------- ; ; Window Manager Globals ; ;---------------------------- ; WINDOWLIST .EQU TOOLSCRATCH+8 ;Z-ordered list of windows (nearest first) SAVEUPDATE .EQU WINDOWLIST+4 ;boolean enabling update accumulation PAINTWHITE .EQU SAVEUPDATE+2 ;boolean enabling erasing newly drawn windows WMGRPORT .EQU PAINTWHITE+2 ;grafPort used by window manager DESKPORT .EQU WMGRPORT+4 ;wide open port for use by applications ; OLDSTRUCTURE .EQU DESKPORT+4 ;handle to saved structure region OLDCONTENT .EQU OLDSTRUCTURE+4 ;handle to saved content region GRAYRGN .EQU OLDCONTENT+4 ;handle of rounded gray desk region SAVEVISRGN .EQU GRAYRGN+4 ;handle of temporarily saved vis region DRAGHOOK .EQU SAVEVISRGN+4 ;proc ptr to allow user control during dragging TEMPRECT .EQU DRAGHOOK+4 ;rectangle used as scratch by toolbox ONEONE .EQU TempRect+8 ;long constant $00010001 MINUSONE .EQU OneOne+4 ;long constant $FFFFFFFF ;----------------------------------------------- ; ; General purpose bitMap for plotting bitMaps ; ;----------------------------------------------- ICONBITMAP .EQU MinusOne+8 ;bitmap used for plotting things ;---------------------------- ; ; Menu Manager Globals ; ;---------------------------- MENULIST .EQU ICONBITMAP+14 ;pointer to current menuBar list structure MBARENABLE .EQU MENULIST+4 ;word for enabling menuBar for deskOrns CurDeKind .EQU MBARENABLE+2 ;kind of deactivated window MENUFLASH .EQU CurDeKind+2 ;integer holding flash feedback count THEMENU .EQU MENUFLASH+2 ;integer holding ID of hilited menu SAVEDHANDLE .EQU THEMENU+2 ;handle of saved menuBits MRMACHOOK .EQU SAVEDHANDLE+4 ;hook for Mr. MacIntosh MENUHOOK .EQU MRMACHOOK+4 ;hook for user control during menuSelect ; Control Manager Globals DragPattern .EQU MenuHook+4 ;pattern DragTheRgn uses DeskPattern .EQU DragPattern+8 ;pattern to paint the desk with DragFlag .EQU DeskPattern+8 ;implicit parameter to DragControl, 1 word CurDragAction .EQU DragFlag+2 ;implicit actionProc parameter ; Floating Point Package Globals FPState .EQU CurDragAction+4 ;6 bytes of floating point state ;----------------------------- ; ; Resource Manager Globals ; ;----------------------------- TopMapHndl .EQU FPState+6 ;Handle to topmost map of list SysMapHndl .EQU TopMapHndl+4 ;Handle to system map SysMap .EQU SysMapHndl+4 ;reference number of system map CurMap .EQU SysMap+2 ;reference number of current map ResReadOnly .EQU CurMap+2 ;ReadOnly flag ResLoad .EQU ResReadOnly+2 ;Auto-load feature ResErr .EQU ResLoad+2 ;Resource error code ;------------------------------- ; ; Misc ToolBox Globals ; ;------------------------------- TaskLock .EQU ResErr+2 ;flag to prevent re-entering SystemTask FScaleDisable .EQU TaskLock+1 ;flag to disable font scaling CurActivate .EQU FScaleDisable+1 ;window to receive activate event CurDeactive .EQU CurActivate+4 ;window to receive deactivate event DeskHook .EQU CurDeactive+4 ;hook for painting the desk teDoText .EQU DeskHook+4 ;Text edit private hook teRecal .EQU teDoText+4 ; "" MicroSoft .EQU teRecal+4 ;12 bytes for our friends in Seattle GhostWindow .EQU MicroSoft+12 ;window that FrontWindow ignores CloseOrnHook .EQU GhostWindow+4 ;hook for closing desk ornaments ;-------------------------------------------------------------- ; ; Alert/Dialog Manager Globals ; ;-------------------------------------------------------------- RestProc .EQU CloseOrnHook+4 ;Address of Restart failsafe procedure SaveProc .EQU RestProc+4 ;Address of Save failsafe procedure SaveSP .EQU SaveProc+4 ;Safe SP for restart or save ANumber .EQU SaveSP+4 ;Which alert is active? ACount .EQU ANumber+2 ;How many times this alert called? DABeeper .EQU ACount+2 ;Beep routine DAStrings .EQU DABeeper+4 ;string parameters for substutution ;-------------------------------------------------------------- ; ; TextEdit Globals ; ;-------------------------------------------------------------- TEScrpLength .EQU DAStrings+16 TEScrpHandle .EQU TEScrpLength+4 ; application package dispatch table -- 8 longWords AppPacks .EQU TEScrpHandle+4 ;handle to math code ; Misc stuff (last minute additions) SysResName .EQU AppPacks+32 ;name of system.rsrc AppParmHandle .EQU SysResName+20 ;handle to hold application parameters DSErrCode .EQU AppParmHandle+4 ;last deep shit alert ID ResErrProc .EQU DSErrCode+2 ;Resource error proc. teWdBreak .EQU ResErrProc+4 ;default word break routine dlgFont .EQU teWdBreak+4 ;default dialog font LastTGLobal .EQU dlgFont+2 ;address of last global ;--------------------------------------------------- ; ; ToolBox Data Structure Definitions ; ; This section contains data structure definitions ; for the font manager, the window manager ; and the menu manager. ; ;--------------------------------------------------- ;--------------------------------------- ; ; Font Manager Data Structures ; ;--------------------------------------- SYSFONT .EQU 0 ;system font is font ID 0 APPLFONT .EQU 1 ;application font is font ID 1 ; Font Manager Input Record Offsets FMInFamily .EQU 0 ;offset to family FMInSize .EQU 2 ;offset to size FMInFace .EQU 4 ;offset to face FMInNeedBits .EQU 5 ;offset to needBits boolean FMInDevice .EQU 6 ;offset to device number FMInNumer .EQU 8 ;offset to numerator of scale FMInDenom .EQU 12 ;offset to denominator of scale ; ; Kerned Strike Font Header Data Structure ; FFORMAT .EQU 0 ;format of font FMINCHAR .EQU 2 ;lowest character in font FMAXCHAR .EQU 4 ;highest character in font FMAXWD .EQU 6 ;maximum width of characters FBBOX .EQU 8 ;left side of bounding box FBBOY .EQU 10 ;top of bounding box FBBDX .EQU 12 ;width of bounding box FBBDY .EQU 14 ;height of bounding box FLENGTH .EQU 16 ;length of font FASCENT .EQU 18 ;ascent above baseline FDESCENT .EQU 20 ;descent below baseline FLEADING .EQU 22 ;space between lines FRASTER .EQU 24 ;offset to actual bits? ; ; Definitions for Font Style Bits (in standard style byte, bits 0-6) ; BOLDBIT .EQU 0 ITALICBIT .EQU 1 ULINEBIT .EQU 2 OUTLINEBIT .EQU 3 SHADOWBIT .EQU 4 CondenseBit .EQU 5 ExtendBit .EQU 6 ; Font Manager Defined control/status codes FMgrCtl1 .EQU 8 ;printer drivers support ctl/status 8 ;--------------------------------------- ; ; Window Manager Data Structures ; ;--------------------------------------- ; ; Window Kind Constants ; ; ;system windows are negative include desk ornaments, etc. DialogKind .EQU 2 ;Dialog windows USERKIND .EQU 8 ;this and above numbers are for user ; ; Window Definition Procedure Messages ; WDRAWMSG .EQU 0 ;draw yourself WHITMSG .EQU 1 ;hit test WCALCRGNMSG .EQU 2 ;recalculate your regions WINITMSG .EQU 3 ;initialize yourself WDISPOSEMSG .EQU 4 ;dispose any private data WGROWMSG .EQU 5 ;drag out grow outline WGIconMsg .EQU 6 ;draw the grow icon ; ; Window Hit-Test Codes ; wNoHit .EQU 0 ;not in window at all wInContent .EQU 1 ;in content area of window wInDrag .EQU 2 ;in drag area of window wInGrow .EQU 3 ;in grow area of window wInGoAway .EQU 4 ;in go away area of window ; ; Window Data Structure Definition ; WINDOWPORT .EQU 0 ;GrafPort Data Structure WINDOWKIND .EQU GPORTSIZE ;integer -- logical type of window WVISIBLE .EQU WINDOWKIND+2 ;boolean (1 byte) -- visible flag WHILITED .EQU WVISIBLE+1 ;boolean (1 byte) -- select (hilite) flag WGoAway .EQU WHilited+1 ;boolean (1 byte) -- has go away button WSpare .EQU WGoAway+1 ;spare byte reserved for future expansion STRUCTRGN .EQU WSpare+1 ;handle to structure region of window CONTRGN .EQU STRUCTRGN+4 ;handle to content region of window UPDATERGN .EQU CONTRGN+4 ;handle to update region of window WINDOWDEF .EQU UPDATERGN+4 ;handle to window definition procedure WDATAHANDLE .EQU WINDOWDEF+4 ;handle to window proc-defined data WTITLEHANDLE .EQU WDATAHANDLE+4 ;handle to title string WTITLEWIDTH .EQU WTITLEHANDLE+4 ;width in pixels of title string (integer) WCONTROLLIST .EQU WTITLEWIDTH+2 ;handle to list of controls of this window NEXTWINDOW .EQU WCONTROLLIST+4 ;pointer to next window in z-ordered list WINDOWPIC .EQU NEXTWINDOW+4 ;picture handle for updates WREFCON .EQU WINDOWPIC+4 ;long integer defined by application ; WINDOWSIZE .EQU WREFCON+4 ;size of window data structure ;-------------------------------------------------- ; ; Menu Manager Data Structure Definitions ; ;-------------------------------------------------- MAXMENU .EQU 96 ;a maximum of 16*6 menus in menuBar MLISTSIZE .EQU 102 ;a menu list is 102 bytes long ; ; Menu Definition Procedure Messages ; MDRAWMSG .EQU 0 ;draw yourself MCHOOSEMSG .EQU 1 ;select an item MSizeMsg .EQU 2 ;calculate your size ; ; Character Definitions for MenuMarks and other special characters ; NOMARK .EQU 0 APPLEMARK .EQU 17 CHECKMARK .EQU 18 ; ; MenuList Data Structure Definition -- one per menuBar ; LASTMENU .EQU 0 ;number of menus in this menuList LASTRIGHT .EQU 2 ;coordinate of 1st free point in menuBar MENUOH .EQU 0 ;menu handle MENULEFT .EQU 4 ;coordinate of left edge of menu ; ; MenuInfoBlk Data Structure -- one per menu ; MENUID .EQU 0 ;16 bit integer unique for each menuBar MENUWIDTH .EQU 2 ;16 bit integer indicating menu width MENUHEIGTH .EQU 4 ;16 bit integer indicating menu height MenuDefHandle .EQU 6 ;handle to menu definition proc MENUENABLE .EQU 10 ;longword of enable flags, one bit/item MENUDATA .EQU 14 ;menu item string ; MENUBLKSIZE .EQU 14 ;size of a menu block is 14 bytes plus H;the dataString ; ; MenuString Data Structure -- one per item ; ITEMICON .EQU 0 ;offset to icon byte ITEMCMD .EQU 1 ;offset to apple (command key) byte ITEMMARK .EQU 2 ;offset to checkmark character byte ITEMSTYLE .EQU 3 ;offset to style byte ;------------------------------------------------------------------ ; ; Control Manager (button and dial) manager data structures ; ;------------------------------------------------------------------ ; ; Control Definition Procedure Messages ; DrawCtlMsg .EQU 0 ;draw message HitCtlMsg .EQU 1 ;hit test message CalcCtlMsg .EQU 2 ;calc region message NewCtlMsg .EQU 3 ;init message DispCtlMsg .EQU 4 ;dispose any private data message PosCtlMsg .EQU 5 ;adjust indicator position message ThumbCtlMsg .EQU 6 ;calculate rectangles for thumb dragging DragCtlMsg .EQU 7 ;custom drag message TrackCtlMsg .EQU 8 ;track yourself message ; ; FindWindow classification codes ; inDesk .EQU 0 ;not in any window inMenuBar .EQU 1 ;in the menu bar inSysWindow .EQU 2 ;in a system window inContent .EQU 3 ;in content area of user window inDrag .EQU 4 ;in drag area of user window inGrow .EQU 5 ;in grow area of user window inGoAway .EQU 6 ;in go away area of user window ; inButton .EQU 10 ;in a push button inCheckBox .EQU 11 ;in a checkBox button ; inUpButton .EQU 20 ;in up button area of a dial inDownButton .EQU 21 ;in down button area of a dial inPageUp .EQU 22 ;in page up (gray) area of a dial inPageDown .EQU 23 ;in page down (gray) area of a dial ; inThumb .EQU 129 ;in thumb area of a dial ; NEXTCONTROL .EQU 0 ;handle to next control in the list CONTRLOWNER .EQU NEXTCONTRL+4 ;windowPtr to owning window CONTRLRECT .EQU CONTRLOWNER+4 ;bounding rectangle of control CONTRLVIS .EQU CONTRLRECT+8 ;one byte boolean indicating visible state CONTRLHILITE .EQU CONTRLVIS+1 ;one byte field indicating hilite state CONTRLVALUE .EQU CONTRLHILITE+1 ;integer holding current value of control CONTRLMIN .EQU CONTRLVALUE+2 ;integer holding minimum value of control CONTRLMAX .EQU CONTRLMIN+2 ;integer holding maximum value of control CONTRLDefHandle .EQU CONTRLMAX+2 ;handle to control definition procedure CONTRLDATA .EQU CONTRLDefHand+4 ;pointer to data handle for definition proc ContrlAction .EQU ContrlData+4 ;pointer to local actionProc CONTRLRFCON .EQU ContrlAction+4 ;longword refcon defined by application CONTRLTITLE .EQU CONTRLRFCON+4 ;handle to title string (or string itself) CONTRLSIZE .EQU CONTRLTITLE ;size of control data structure - title ;------------------------------------------------ ; ; Alert Box Manager Data Structure Definitions ; ;------------------------------------------------ ;Dialog record DBounds .EQU 0 ;Dialog bounds rectangle DVisible .EQU DBounds+8 ;Visible flag DWindProc .EQU DVisible+2 ;Window proc ID DGoAway .EQU DWindProc+2 ;Go away flag DRefCon .EQU DGoAway+2 ;Reference constant DItems .EQU DRefCon+4 ;Item list ID and handle DTitle .EQU DItems+2 ;Dialog window title ;Alert record ABounds .EQU 0 ;Alert box height and width AItems .EQU ABounds+8 ;Item list ID AStages .EQU AItems+2 ;Stages word ;Window subclass DialogWindow Items .EQU WindowSize ;Item list teHandle .EQU Items+4 ;handle to TextEdit object EditField .EQU teHandle+4 ;current field being edited EditOpen .EQU EditField+2 ;Is editting open? ADefItem .EQU EditOpen+2 ;default item for alerts DWindLen .EQU ADefItem+2 ;Dialog window length ;stage definition--packed 2 to a byte, 4 stages in a word volBits .EQU 3 ;Low 2 bits are volume (0..3) alBit .EQU 4 ;alert bit (put up box this time?) OKDismissal .EQU 8 ;bit for OK/Cancel default in each stage H;(not necessarily different for each H; stage, but saves a byte) ;------------------------------------------------ ; ; DialogList Data Structure Definitions ; ;------------------------------------------------ DlgMaxIndex .EQU 0 ;Maximum index (=items-1) stored here ;In each item ItmHndl .EQU 0 ;Handle to the item ItmRect .EQU ItmHndl+4 ;Bounding rect of item ItmType .EQU ItmRect+8 ;item type ItmData .EQU ItmType+1 ;item string, must be even length ;------------------------------------------------------------------ ; ; ToolBox Error Codes (passed through GrafError) ; ;------------------------------------------------------------------ FontDecError .EQU -64 ;error during font declaration FontNotDeclared .EQU -65 ;font not declared FontSubErr .EQU -66 ;font substitution occured ; ;------------------------------------------------------------------ ; ; Equates for journal interface control call ; ;------------------------------------------------------------------ JPlayCtl .EQU 16 ; playBack call JRecordCtl .EQU 17 ; record call JRefNum .EQU -2 ; refNum of journal jcTickCount .EQU 0 ; journal code for TickCount jcGetMouse .EQU 1 ; journal code for GetMouse jcButton .EQU 2 ; journal code for Button jcGetKeys .EQU 3 ; journal code for GetKeys jcEvent .EQU 4 ; journal code for GetNextEvent(Avail) ;------------------------------------------------------------------ ; ; Record for Text Edit object ; ;------------------------------------------------------------------ teDestRect .EQU 0 ; 0 Destination rectangle (keep together) teViewRect .EQU teDestRect+8 ; 8 View rectangle rectangle teSelRect .EQU teViewRect+8 ; 10 Select rectangle teLineHite .EQU teSelRect+8 ; 18 Current font lineheight teAscent .EQU teLineHite+2 ; 1A Current font ascent teSelPoint .EQU teAscent+2 ; 1C Selection point(mouseLoc) teSelStart .EQU teSelPoint+4 ; 20 selection start (KEEP together) teSelEnd .EQU teSelStart+2 ; 22 selection end teActive .EQU teSelEnd+2 ; 24 ST if active teWordBreak .EQU teActive+2 ; 26 Word break routine teClikProc .EQU teWordBreak+4 ; 2A Click loop routine teClikTime .EQU teClikProc+4 ; 2E Time of last click teClikLoc .EQU teClikTime+4 ; 32 location of double click teCarTime .EQU teClikLoc+2 ; 33 Time for next caret toggle teCarOn .EQU teCarTime+4 ; 38 Is caret on? teCarAct .EQU teCarOn+1 ; 39 Is caret active? teStyle .EQU teCarAct+1 ; 3A fill style teLength .EQU teStyle+2 ; 3C Length of text below {Must stay together} teTextH .EQU teLength+2 ; 40 text handle goes here teRecBack .EQU teTextH+4 ; 42 set true if backgnd recal teRecLine .EQU teRecBack+2 ; 44 current recal line teLftClick .EQU teRecLine+2 ; 46 ST if click was to left teLftCaret .EQU teLftClick+1 ; 47 ST if caret was to left teCROnly .EQU teLftCaret+1 ; 48 ST if CR only for line breaks teFontStuff .EQU teCROnly+2 ; 50 space for font specifier teGrafPort .EQU teFontStuff+8 ; 52 grafport for editting teHiHook .EQU teGrafPort+4 ; 56 Hook for hilite routine teCarHook .EQU teHiHook+4 ; 5A Hook for hilite routine teNLines .EQU teCarHook+4 ; 5E number of lines (must keep together) teLines .EQU teNLines+2 ; 62 line starts(array of words) TERecSize .EQU teLines+8 ; 6A BASE size of a record 5P:H r^;File ToolMacs.Text ;----------------------------------------------------- ; ; User Interface ToolBox Assembly Language Interface ; ; These macros expand into toolBox traps allowing ; a convenient, symbolic ToolBox interface for the ; assembly lanaguage programmer. ; ; Version for ROM 2.0 -- Februrary 10, 1983 ; regenerated for ROM 4.0 -- June 3, 1983 ; changed AlertSound to ErrorSound ; added InsertResMenu, OpenDeskAcc -- June 13, 1983 ; added UniqueID, CloseDeskAcc,SystemEdit,LBin2Dec,LDec2Bin ; Secs2Date,Date2Secs; removed sound traps -- July 2, 1983 ; added TEGetText, TESetJust and TEInsert - august 4 ; added SysBeep, DrawGrow - august 6 ; added HandAndHand, PtrAndHand - august 6 ; Removed EndSubResource. Changed BeginSubResource to HomeResFile. ; added GetFinderInfo and SetFinderInfo - august 6 ; added DragGrayRgn - august 11 ; Removed GetFinderInfo and SetFinderInfo (august 18?) ; Added scrap macros ; Added resource set/getresfileattr ; Added EnQueue, DeQueue (19-Dec-83, LAK) ; Added CouldDialog, FreeDialog, SizeRsrc (12-Jan-84, LAK) ; ;----------------------------------------------------- 0.MACRO _InitFont 0.WORD $A8FE 0.ENDM 0.MACRO _GetFName 0.WORD $A8FF 0.ENDM 0.MACRO _GetFNum 0.WORD $A900 0.ENDM 0.MACRO _FMSwapFo 0.WORD $A901 0.ENDM 0.MACRO _RealFont 0.WORD $A902 0.ENDM 0.MACRO _SetFontL 0.WORD $A903 0.ENDM 0.MACRO _DrawGrow 0.WORD $A904 0.ENDM 0.MACRO _DragGrayRgn 0.WORD $A905 0.ENDM 0.MACRO _NewStrin 0.WORD $A906 0.ENDM 0.MACRO _SetStrin 0.WORD $A907 0.ENDM 0.MACRO _ShowHide 0.WORD $A908 0.ENDM 0.MACRO _CalcVis 0.WORD $A909 0.ENDM 0.MACRO _CalcVBehind 0.WORD $A90A 0.ENDM 0.MACRO _ClipAbov 0.WORD $A90B 0.ENDM 0.MACRO _PaintOne 0.WORD $A90C 0.ENDM 0.MACRO _PaintBeh 0.WORD $A90D 0.ENDM 0.MACRO _SaveOld 0.WORD $A90E 0.ENDM 0.MACRO _DrawNew 0.WORD $A90F 0.ENDM 0.MACRO _GetWMgrP 0.WORD $A910 0.ENDM 0.MACRO _CheckUpD 0.WORD $A911 0.ENDM 0.MACRO _InitWind 0.WORD $A912 0.ENDM 0.MACRO _NewWindo 0.WORD $A913 0.ENDM 0.MACRO _DisposWindow 0.WORD $A914 0.ENDM 0.MACRO _ShowWind 0.WORD $A915 0.ENDM 0.MACRO _HideWind 0.WORD $A916 0.ENDM 0.MACRO _GetWRefC 0.WORD $A917 0.ENDM 0.MACRO _SetWRefC 0.WORD $A918 0.ENDM 0.MACRO _GetWTitl 0.WORD $A919 0.ENDM 0.MACRO _SetWTitl 0.WORD $A91A 0.ENDM 0.MACRO _MoveWind 0.WORD $A91B 0.ENDM 0.MACRO _HiliteWi 0.WORD $A91C 0.ENDM 0.MACRO _SizeWind 0.WORD $A91D 0.ENDM 0.MACRO _TrackGoA 0.WORD $A91E 0.ENDM 0.MACRO _SelectWi 0.WORD $A91F 0.ENDM 0.MACRO _BringToF 0.WORD $A920 0.ENDM 0.MACRO _SendBehi 0.WORD $A921 0.ENDM 0.MACRO _BeginUpD 0.WORD $A922 0.ENDM 0.MACRO _EndUpDat 0.WORD $A923 0.ENDM 0.MACRO _FrontWin 0.WORD $A924 0.ENDM 0.MACRO _DragWind 0.WORD $A925 0.ENDM 0.MACRO _DragTheR 0.WORD $A926 0.ENDM 0.MACRO _InvalRgn 0.WORD $A927 0.ENDM 0.MACRO _InvalRec 0.WORD $A928 0.ENDM 0.MACRO _ValidRgn 0.WORD $A929 0.ENDM 0.MACRO _ValidRec 0.WORD $A92A 0.ENDM 0.MACRO _GrowWind 0.WORD $A92B 0.ENDM 0.MACRO _FindWind 0.WORD $A92C 0.ENDM 0.MACRO _CloseWin 0.WORD $A92D 0.ENDM 0.MACRO _SetWindo 0.WORD $A92E 0.ENDM 0.MACRO _GetWindo 0.WORD $A92F 0.ENDM 0.MACRO _InitMenu 0.WORD $A930 0.ENDM 0.MACRO _NewMenu 0.WORD $A931 0.ENDM 0.MACRO _DisposMenu 0.WORD $A932 0.ENDM 0.MACRO _AppendMe 0.WORD $A933 0.ENDM 0.MACRO _ClearMen 0.WORD $A934 0.ENDM 0.MACRO _InsertMe 0.WORD $A935 0.ENDM 0.MACRO _DeleteMe 0.WORD $A936 0.ENDM 0.MACRO _DrawMenu 0.WORD $A937 0.ENDM 0.MACRO _HiliteMe 0.WORD $A938 0.ENDM 0.MACRO _EnableIt 0.WORD $A939 0.ENDM 0.MACRO _DisableI 0.WORD $A93A 0.ENDM 0.MACRO _GetMenuB 0.WORD $A93B 0.ENDM 0.MACRO _SetMenuB 0.WORD $A93C 0.ENDM 0.MACRO _MenuSele 0.WORD $A93D 0.ENDM 0.MACRO _MenuKey 0.WORD $A93E 0.ENDM 0.MACRO _GetItmIcon 0.WORD $A93F 0.ENDM 0.MACRO _SetItmIcon 0.WORD $A940 0.ENDM 0.MACRO _GetItmStyle 0.WORD $A941 0.ENDM 0.MACRO _SetItmStyle 0.WORD $A942 0.ENDM 0.MACRO _GetItmMark 0.WORD $A943 0.ENDM 0.MACRO _SetItmMark 0.WORD $A944 0.ENDM 0.MACRO _CheckIte 0.WORD $A945 0.ENDM 0.MACRO _GetItem 0.WORD $A946 0.ENDM 0.MACRO _SetItem 0.WORD $A947 0.ENDM 0.MACRO _CalcMenu 0.WORD $A948 0.ENDM 0.MACRO _GetMHand 0.WORD $A949 0.ENDM 0.MACRO _SetMFlash 0.WORD $A94A 0.ENDM 0.MACRO _PlotIcon 0.WORD $A94B 0.ENDM 0.MACRO _FlashMen 0.WORD $A94C 0.ENDM 0.MACRO _AddResMe 0.WORD $A94D 0.ENDM 0.MACRO _CountMIt 0.WORD $A950 0.ENDM 0.MACRO _InsertResMenu 0.WORD $A951 0.ENDM 0.MACRO _PinRect 0.WORD $A94E 0.ENDM 0.MACRO _DeltaPoi 0.WORD $A94F 0.ENDM 0.MACRO _NewContr 0.WORD $A954 0.ENDM 0.MACRO _DisposControl 0.WORD $A955 0.ENDM 0.MACRO _KillCont 0.WORD $A956 0.ENDM 0.MACRO _ShowCont 0.WORD $A957 0.ENDM 0.MACRO _HideCont 0.WORD $A958 0.ENDM 0.MACRO _MoveCont 0.WORD $A959 0.ENDM 0.MACRO _GetCRefC 0.WORD $A95A 0.ENDM 0.MACRO _SetCRefC 0.WORD $A95B 0.ENDM 0.MACRO _SizeCont 0.WORD $A95C 0.ENDM 0.MACRO _HiliteCo 0.WORD $A95D 0.ENDM 0.MACRO _GetCTitl 0.WORD $A95E 0.ENDM 0.MACRO _SetCTitl 0.WORD $A95F 0.ENDM 0.MACRO _GetCtlVa 0.WORD $A960 0.ENDM 0.MACRO _GetMinCtl 0.WORD $A961 0.ENDM 0.MACRO _GetMaxCtl 0.WORD $A962 0.ENDM 0.MACRO _SetCtlVa 0.WORD $A963 0.ENDM 0.MACRO _SetMinCtl 0.WORD $A964 0.ENDM 0.MACRO _SetMaxCtl 0.WORD $A965 0.ENDM 0.MACRO _TestCont 0.WORD $A966 0.ENDM 0.MACRO _DragCont 0.WORD $A967 0.ENDM 0.MACRO _TrackCon 0.WORD $A968 0.ENDM 0.MACRO _DrawCont 0.WORD $A969 0.ENDM 0.MACRO _GetCtlAc 0.WORD $A96A 0.ENDM 0.MACRO _SetCtlAc 0.WORD $A96B 0.ENDM 0.MACRO _FindCont 0.WORD $A96C 0.ENDM 0.MACRO _DeQueue 0.WORD $A96E 0.ENDM 0.MACRO _EnQueue 0.WORD $A96F 0.ENDM 0.MACRO _GetNextE 0.WORD $A970 0.ENDM 0.MACRO _EventAva 0.WORD $A971 0.ENDM 0.MACRO _GetMouse 0.WORD $A972 0.ENDM 0.MACRO _StillDow 0.WORD $A973 0.ENDM 0.MACRO _Button 0.WORD $A974 0.ENDM 0.MACRO _TickCoun 0.WORD $A975 0.ENDM 0.MACRO _GetKeys 0.WORD $A976 0.ENDM 0.MACRO _WaitMous 0.WORD $A977 0.ENDM 0.MACRO _CouldDialog 0.WORD $A979 0.ENDM 0.MACRO _FreeDialog 0.WORD $A97A 0.ENDM 0.MACRO _InitDial 0.WORD $A97B 0.ENDM 0.MACRO _GetNewDi 0.WORD $A97C 0.ENDM 0.MACRO _NewDialo 0.WORD $A97D 0.ENDM 0.MACRO _SelIText 0.WORD $A97E 0.ENDM 0.MACRO _IsDialog 0.WORD $A97F 0.ENDM 0.MACRO _DialogSe 0.WORD $A980 0.ENDM 0.MACRO _DrawDial 0.WORD $A981 0.ENDM 0.MACRO _CloseDia 0.WORD $A982 0.ENDM 0.MACRO _DisposDi 0.WORD $A983 0.ENDM 0.MACRO _Alert 0.WORD $A985 0.ENDM 0.MACRO _StopAler 0.WORD $A986 0.ENDM 0.MACRO _NoteAler 0.WORD $A987 0.ENDM 0.MACRO _CautionA 0.WORD $A988 0.ENDM 0.MACRO _CouldAle 0.WORD $A989 0.ENDM 0.MACRO _FreeAler 0.WORD $A98A 0.ENDM 0.MACRO _ParamTex 0.WORD $A98B 0.ENDM 0.MACRO _ErrorSou 0.WORD $A98C 0.ENDM 0.MACRO _GetDItem 0.WORD $A98D 0.ENDM 0.MACRO _SetDItem 0.WORD $A98E 0.ENDM 0.MACRO _SetIText 0.WORD $A98F 0.ENDM 0.MACRO _GetIText 0.WORD $A990 0.ENDM 0.MACRO _ModalDia 0.WORD $A991 0.ENDM 0.MACRO _DetachRe 0.WORD $A992 0.ENDM 0.MACRO _SetResPu 0.WORD $A993 0.ENDM 0.MACRO _CurResFi 0.WORD $A994 0.ENDM 0.MACRO _InitReso 0.WORD $A995 0.ENDM 0.MACRO _RsrcZone 0.WORD $A996 0.ENDM 0.MACRO _OpenResF 0.WORD $A997 0.ENDM 0.MACRO _UseResFi 0.WORD $A998 0.ENDM 0.MACRO _UpdateRe 0.WORD $A999 0.ENDM 0.MACRO _CloseRes 0.WORD $A99A 0.ENDM 0.MACRO _SetResLo 0.WORD $A99B 0.ENDM 0.MACRO _CountRes 0.WORD $A99C 0.ENDM 0.MACRO _GetIndRe 0.WORD $A99D 0.ENDM 0.MACRO _CountTyp 0.WORD $A99E 0.ENDM 0.MACRO _GetIndTy 0.WORD $A99F 0.ENDM 0.MACRO _GetResou 0.WORD $A9A0 0.ENDM 0.MACRO _GetNamed 0.WORD $A9A1 0.ENDM 0.MACRO _LoadReso 0.WORD $A9A2 0.ENDM 0.MACRO _ReleaseR 0.WORD $A9A3 0.ENDM 0.MACRO _HomeResF 0.WORD $A9A4 0.ENDM 0.MACRO _SizeRsrc 0.WORD $A9A5 0.ENDM 0.MACRO _GetResAt 0.WORD $A9A6 0.ENDM 0.MACRO _SetResAt 0.WORD $A9A7 0.ENDM 0.MACRO _GetResIn 0.WORD $A9A8 0.ENDM 0.MACRO _SetResIn 0.WORD $A9A9 0.ENDM 0.MACRO _ChangedR 0.WORD $A9AA 0.ENDM 0.MACRO _AddResou 0.WORD $A9AB 0.ENDM 0.MACRO _AddRefer 0.WORD $A9AC 0.ENDM 0.MACRO _RmveReso 0.WORD $A9AD 0.ENDM 0.MACRO _RmveRefe 0.WORD $A9AE 0.ENDM 0.MACRO _ResError 0.WORD $A9AF 0.ENDM 0.MACRO _WriteRes 0.WORD $A9B0 0.ENDM 0.MACRO _CreateRe 0.WORD $A9B1 0.ENDM 0.MACRO _SystemEv 0.WORD $A9B2 0.ENDM 0.MACRO _SystemCl 0.WORD $A9B3 0.ENDM 0.MACRO _SystemTa 0.WORD $A9B4 0.ENDM 0.MACRO _SystemMe 0.WORD $A9B5 0.ENDM 0.MACRO _OpenDeskAcc 0.WORD $A9B6 0.ENDM 0.MACRO _CloseDeskAcc 0.WORD $A9B7 0.ENDM 0.MACRO _GetPatte 0.WORD $A9B8 0.ENDM 0.MACRO _GetCurso 0.WORD $A9B9 0.ENDM 0.MACRO _GetStrin 0.WORD $A9BA 0.ENDM 0.MACRO _GetIcon 0.WORD $A9BB 0.ENDM 0.MACRO _GetPictu 0.WORD $A9BC 0.ENDM 0.MACRO _GetNewWi 0.WORD $A9BD 0.ENDM 0.MACRO _GetNewCo 0.WORD $A9BE 0.ENDM 0.MACRO _GetRMenu 0.WORD $A9BF 0.ENDM 0.MACRO _GetNewMB 0.WORD $A9C0 0.ENDM 0.MACRO _UniqueID 0.WORD $A9C1 0.ENDM 0.MACRO _SysEdit 0.WORD $A9C2 0.ENDM 0.MACRO _LBin2Dec 0.WORD $A9C4 0.ENDM 0.MACRO _LDec2Bin 0.WORD $A9C5 0.ENDM 0.MACRO _Secs2Date 0.WORD $A9C6 0.ENDM 0.MACRO _Date2Secs 0.WORD $A9C7 0.ENDM 0.MACRO _SysBeep 0.WORD $A9C8 0.ENDM 0.MACRO _SysError 0.WORD $A9C9 0.ENDM 0.MACRO _PutIcon 0.WORD $A9CA 0.ENDM 0.MACRO _TEGetText 0.WORD $A9CB 0.ENDM 0.MACRO _TEInit 0.WORD $A9CC 0.ENDM 0.MACRO _TEDispos 0.WORD $A9CD 0.ENDM 0.MACRO _TextBox 0.WORD $A9CE 0.ENDM 0.MACRO _TESetText 0.WORD $A9CF 0.ENDM 0.MACRO _TECalTex 0.WORD $A9D0 0.ENDM 0.MACRO _TESetSel 0.WORD $A9D1 0.ENDM 0.MACRO _TENew 0.WORD $A9D2 0.ENDM 0.MACRO _TEUpdate 0.WORD $A9D3 0.ENDM 0.MACRO _TEClick 0.WORD $A9D4 0.ENDM 0.MACRO _TECopy 0.WORD $A9D5 0.ENDM 0.MACRO _TECut 0.WORD $A9D6 0.ENDM 0.MACRO _TEDelete 0.WORD $A9D7 0.ENDM 0.MACRO _TEActiva 0.WORD $A9D8 0.ENDM 0.MACRO _TEDeacti 0.WORD $A9D9 0.ENDM 0.MACRO _TEIdle 0.WORD $A9DA 0.ENDM 0.MACRO _TEPaste 0.WORD $A9DB 0.ENDM 0.MACRO _TEKey 0.WORD $A9DC 0.ENDM 0.MACRO _TEScroll 0.WORD $A9DD 0.ENDM 0.MACRO _TEInsert 0.WORD $A9DE 0.ENDM 0.MACRO _TESetJust 0.WORD $A9DF 0.ENDM 0.MACRO _Munger 0.WORD $A9E0 0.ENDM 0.MACRO _HandToHa 0.WORD $A9E1 0.ENDM 0.MACRO _PtrToXHa 0.WORD $A9E2 0.ENDM 0.MACRO _PtrToHan 0.WORD $A9E3 0.ENDM 0.MACRO _HandAndH 0.WORD $A9E4 0.ENDM 0.MACRO _InitPack 0.WORD $A9E5 0.ENDM 0.MACRO _InitMath 0.WORD $A9E6 0.ENDM 0.MACRO _Pack0 0.WORD $A9E7 0.ENDM 0.MACRO _Pack1 0.WORD $A9E8 0.ENDM 0.MACRO _Pack2 0.WORD $A9E9 0.ENDM 0.MACRO _Pack3 0.WORD $A9EA 0.ENDM 0.MACRO _FP68K ;same as Pack4 0.WORD $A9EB 0.ENDM 0.MACRO _Pack4 0.WORD $A9EB 0.ENDM 0.MACRO _Pack5 0.WORD $A9EC 0.ENDM 0.MACRO _Pack6 0.WORD $A9ED 0.ENDM 0.MACRO _Pack7 0.WORD $A9EE 0.ENDM 0.MACRO _PtrAndHa 0.WORD $A9EF 0.ENDM 0.MACRO _LoadSeg 0.WORD $A9F0 0.ENDM 0.MACRO _UnLoadSe 0.WORD $A9F1 0.ENDM 0.MACRO _Launch 0.WORD $A9F2 0.ENDM 0.MACRO _Chain 0.WORD $A9F3 0.ENDM 0.MACRO _ExitToSh 0.WORD $A9F4 0.ENDM 0.MACRO _GetAppPa 0.WORD $A9F5 0.ENDM 0.MACRO _GetResFil 0.WORD $A9F6 0.ENDM 0.MACRO _SetResFil 0.WORD $A9F7 0.ENDM 0.MACRO _InfoScra 0.WORD $A9F9 0.ENDM 0.MACRO _UnlodeSc 0.WORD $A9FA 0.ENDM 0.MACRO _LodeScra 0.WORD $A9FB 0.ENDM 0.MACRO _ZeroScra 0.WORD $A9FC 0.ENDM 0.MACRO _GetScrap 0.WORD $A9FD 0.ENDM 0.MACRO _PutScrap 0.WORD $A9FE 0.ENDM W nW‚g"| Hz.Hn?<"HnBgN`B. N^.NuADPORTB*(Baud rate not available on Serial port AJo,NV,Bg?.?-8Nfg`Jm.m Hn?-."8Jm6oHmP?-6Bg nfA C ` A C B.HnHnHnHm "dJn^ nVg$Hm HzHn?<"Hn?.N`\HzHm HzvHn^?<"A C^p S@n0HnHm Hm.?:F"|Jno$Hm Hz"Hn,?<"Hn,?.N`Jm8o$?<Bg?-8N0H//</<N?<p//</<N?< BB/<N?< p-//</<Nr?<B/</<N\0-0gS@g S@gS@g4`J?<B/</<N2`2?<p//</<N`?<p//</<N0-2gZS@gS@gRS@g`?< B/</<N?<B/</<N?< /<p//<N`?</</</<N?</</</<Nj?< /<p//<NR`2?</</</<N6?< /<p//<N;n6;m6~HmP?-6< m6f|`|N^ _TONETUARTP@ can't be opened -serial- can't be mountedRS232BRS232AJoNVBg?-6?.Ng`pJm6o$?<Bg?.N0H//</<NTJm8oHmf?-8Bg;n8;m8Hmf?-8< m6f|`|N^ _TONETUARTSJoNVJm0oHm|?-0Bg;n0;m0Jm6o\0-0S@g S@gS@g4`J?<B/</<N`2?<p//</<N`?<p//</<NrHm|?-0< m6f|`|N^ _TONETPARITJoNVJm2oHm?-2Bg;n2;m2Jm6o0-2S@gS@gRS@g`?< B/</<N?<B/</<N?< /<p//<N`?</</</<N?</</</<Nx?< /<p//<N``L?</</</<ND?</</</<N*?< /<p//<NHm?-2< m6f|`|N^ _TONETHANDSJoNVJm4oHm?-4Bg;n4;m4Hm?-4<N^ _TONETDUPLETransfer/config.textconfig.tΝ@ [&,_V  tty/term.menus.textmenus.teΝ@ [&9+9 5 ND!lL^92 Control Receive from remote ... Receive All Text Receive Filtered Text - Suppress Text Display - Transfer to remote ... Line Delay - Exit 3 Connector Serial A Serial B 4 Baud Rate 50 75 110 134.5 150 200 300 600 1200 1800 2000 2400 3600 4800 9600 19200 5 Parity None Even Odd 6 Handshake None XOn/XOff DTR 7 Duplex Full Half RAMDISK/EXEC..TEXT"^&C:?*=C{C|C|* %Pramdisk/ramstart Gramdisk/ramstart Aramdisk/changeQ Aramdisk/fixSP Aramdisk/ramdisk Lramdisk/ramstart obj/quickdraw obj/tooltraps obj/ostraps obj/macpaslib ramdisk/changeQ ramdisk/ramstart Rrmaker ramdisk/ramdef Rmaccom FYLramdisk/ramstart.rsrc ram start APPL Q %%               '"2"31"42"53"64"75"86"97":8" ;9" <:" =;" ><" ?="@>"A?"B@"CA"DB"EC"FD"GE"HF"IG"JH"KI"JMNLOMPNQORPSQTRUS VT WU XV YW ZX[Y\Z][^\_]`^a_b`cadbecfdgehfigjhkilj mk!nl"om#pn$qo%pstrusvtwuxvywzx{y |z }{ ~| } ~ !"#$%&'()      !"#$%&'()*+,-./01234567                            ! " # $ % & ' ( ) * + , - . /                       !" #!$"%#&$'%(& )' *( +) ,* -+.,-01/201453645897:8;9<:=;><?=@> A? B@ CA DB ECFDGEHFIGJHKILJKNOMPNQORPSQTRUSVT WU XV WZ[Y\Z][^\_]`^a_b` ca db ec fd gehfigjhkiljmknlompnqorpsqtrsvwuxvywzx{y|z}{~| } ~                             !"#$%&'() * +  ,  -        !" #!$"%#&$'%(&)'*(+),*-+ .,!/-"0.#1/$20%31&42'53(64)75*86+97,:8-;9.<:/=;0><1?=2@>3A?4B@5CA6DB7EC8FD9GE:HF;IGLJ?MK@NLAOMBPNCQODRPESQFTRGUSHVTIWUJXVKYWLZXM[YN\ZO][P^\Q_]R`^Sa_Tb`Uadecfdgehfigjhkilj mk nl om pn qorpsqtrusvtwuxvwz{y|z}{~|}~                                       ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9!!!!!!!!!! ! ! ! ! !!!!!!!!!!!!!!"K"""#g$$$$%%%%