Next Page > Hide TOC

Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

NSMenu.MenuValidation

(informal protocol)

Package
com.apple.cocoa.application
Companion guide

Overview

This interface allows your application to update the enabled or disabled status of an NSMenuItem. It declares only one method, validateMenuItem.

Tasks

Validating Menu Items

Instance Methods

validateMenuItem

public abstract boolean validateMenuItem(_NSObsoleteMenuItemProtocol menuItem)

Discussion

Implemented to override the default action of enabling or disabling menuItem. The object implementing this method must be the target of menuItem. It returns true to enable menuItem, false to disable it. You can determine which menu item menuItem is by querying it for its tag or action.



Next Page > Hide TOC


© 1997, 2007 Apple Inc. All Rights Reserved. (Last updated: 2007-02-01)


Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.