Path: utzoo!attcan!uunet!cs.utexas.edu!uwm.edu!rutgers!ncs.dnd.ca!asterix.drev.dnd.ca!louis From: louis@asterix.drev.dnd.ca (Louis Demers) Newsgroups: comp.sys.mac.programmer Subject: Re: Hierarchical menus -- drag delay found, and it's weird Message-ID: <1990Feb12.153745.9468@asterix.drev.dnd.ca> Date: 12 Feb 90 15:37:45 GMT References: <14044@reed.UUCP> <1990Feb5.004034.6097@oracle.com> <28018@brunix.UUCP> <10059@hoptoad.uucp> <2857@draken.nada.kth.se> <1807@milton.acs.washington.edu> <10164@hoptoad.uucp> <1990Feb11.003600.1685@asterix.drev.dnd.ca> Organization: DREV, Defence Research Est. Valcartier Lines: 42 This weekend, I dug through the ROM and MPW 3.0 include files. I found that SubMenu delay is stored at byte 126 of PRAM and the drag delay is at byte 127. At boot time, the values in PRAM are copied into low memory globals. At B5C is stored a handle; at offset 14 and 15 are stored both delays. If you just change the PRAM, you changes will take effect only after you reboot. If the PRAM values are 0, after they are copied to the RAM globals, 8 is added to the submenu delay, and 60 is added to the drag delay. so these are the defaults. To acces the extended PRAM, you need to use ReadXPram ($A051) and WriteXPram ($A052). Both use the same calling convention. A0 points to the data beeing transferred, the upper word of D0 contains the number of bytes to transfer, the lower word of D0 contains the index in PRAM where the transfer will take place. I wrote an MPW tool and experimented with those values and they work ! 8-). I was about to write a cdev, but this morning's news indicate that such a thing is already available. Oh well. Note that my earlier comment about the delay being used only if the movement is in the general direction toward the submenu still holds. History note: I recall seeing a reference to the PRAM on the topic of the menu delays in the beta draft of IM Vol V but in the beta version of the include files, no reference was made to the delays. In the final version of IM Vol V, no reference is made to the PRAM but now the include files give enough information about the delays and the PRAM to use them ! how's that for documentation ? Bye, Louis -- | Louis Demers | DREV, Defence Research Establishment,Valcartier | | louis@asterix.drev.dnd.ca | POBox 8800, Courcelette,Quebec, CANADA, G0A 1R0 | | (131.132.48.2) | Office: (418) 844-4424 fax (418) 844-4511 | +---------------------------+-------------------------------------------------+