Legacy Documentclose button

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

Previous Book Contents Book Index Next

Inside Macintosh: Macintosh Toolbox Essentials /
Chapter 3 - Menu Manager / Menu Manager Reference
Menu Manager Routines / Drawing the Menu Bar


InvalMenuBar

Use the InvalMenuBar procedure to invalidate the menu bar.

PROCEDURE InvalMenuBar; 
DESCRIPTION
The InvalMenuBar procedure marks the menu bar as changed and in need
of updating. When the Event Manager scans update regions for regions that require updating, the Event Manager also checks to determine whether the menu bar
requires updating (because of a call to InvalMenuBar). If the menu bar needs updating, the Event Manager calls the DrawMenuBar procedure to draw the menu bar.

You can use InvalMenuBar instead of DrawMenuBar to minimize blinking in the menu bar. For example, if you have several application-defined routines that can change the enabled state of a menu and each calls DrawMenuBar, you can replace the calls to DrawMenuBar with calls to InvalMenuBar. In this way the menu bar is redrawn only once instead of multiple times in quick succession. If you need to make immediate changes to the menu bar, use DrawMenuBar. If you want to redraw the menu bar at most once each time through your event loop, use InvalMenuBar. The InvalMenuBar procedure is available only in System 7.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 JUL 1996