[comp.sys.mac.programmer] A different MENU/Menu key handling question

paul@morganucodon.cis.ohio-state.edu (Paul Placeway) (04/19/88)

I want to define the key equivelants for MENU entries in the resource
fork of an application (MacKermit), but have a way of turning the
equivalants on and off, hopefully without doing something like:

to turn off a key equiv.:
   get the string equiv. for MENU entry
   remove the string meta character seq. for the key equiv.
   put this string back as the new entry.

to turn on either:
a) same as above except adding the key def. (real bad, since it requires
   coding the key equivalents in the program -- a no no).
or
b) reload the menu defs. from the resource file on disk.


Any suggestions?  Is there something that works like CheckItem?  Should
there be?

		thanks in advance,
			-- Paul Placeway
-=-
Existence is beyond the power of words
To define:
Terms may be used
But are none of them absolute.

lsr@Apple.COM (Larry Rosenstein) (04/26/88)

In article <10904@tut.cis.ohio-state.edu> paul@morganucodon.cis.ohio-state.edu (Paul Placeway) writes:
>
>Any suggestions?  Is there something that works like CheckItem?  Should
>there be?

There are 2 new calls documented in Inside Mac volume 5 called GetItemCmd
and SetItemCmd.  These do exactly what you want to do.  These routines
should be patched onto a Mac Plus running System 4.1 or later.



-- 
		 Larry Rosenstein,  Object Specialist
 Apple Computer, Inc.  20525 Mariani Ave, MS 27-AJ  Cupertino, CA 95014
	    AppleLink:Rosenstein1    domain:lsr@Apple.COM
		UUCP:{sun,voder,nsc,decwrl}!apple!lsr