[Openmcl-devel] The File Menu

Paul Krueger plkrueger at comcast.net
Sun Jan 24 07:11:01 PST 2010


Gary talked about selectors and some of the specific calls for  
manipulating menus and menuitems. I have some additional discussion  
and code examples for manipulating menus in the interface tutorial  
that is in .../ccl/contrib/krueger/InterfaceProjects/Documentation/ 
InterfaceBuilderWithCCLTutorial. If you're not already familiar with  
it, one of the things you'll need to understand to make your changes  
work is the First Responder chain which defines where selectors  
without a specific target are sent. That is discussed in the tutorial.  
If you prefer, it is relatively straightforward to alter the menu  
items so that they send a selector of your choice to a specific object  
of your choice, but then it would be up to you to figure out what  
window was on top (if any) and what document it was associated with so  
that you know what to act on.

Paul

On Jan 24, 2010, at 1:29 AM, Ron Garret wrote:

> Is it possible to change the behavior of items in the File menu?  Is  
> it straightforward?  I want to intercept the SAVE and REVERT items  
> and hook them up to a revision control system.  I tried to reverse  
> engineer the menu but ran into a roadblock when the action selector  
> was just a foreign pointer with no hint as to what it was pointing  
> at.  Is the File menu managed by Lisp at all, or is all of its  
> functionality provided by Cocoa?
>
> Thanks,
> rg
>
> _______________________________________________
> Openmcl-devel mailing list
> Openmcl-devel at clozure.com
> http://clozure.com/mailman/listinfo/openmcl-devel




More information about the Openmcl-devel mailing list