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 6 - Dialog Manager / Dialog Manager Reference
Dialog Manager Routines / Handling Events in Dialog Boxes


DrawDialog

If you don't use any other Dialog Manager routines for handling events in a dialog box, you can use the DrawDialog procedure to draw its entire contents.

PROCEDURE DrawDialog (theDialog: DialogPtr);
theDialog
A pointer to a dialog record.
DESCRIPTION
The DrawDialog procedure draws the entire contents of the specified dialog box. The DrawDialog procedure draws all dialog items, calls the Control Manager procedure DrawControls to draw all controls, and calls the TextEdit procedure TEUpdate to update all static and editable text items and to draw their display rectangles. The DrawDialog procedure also calls the application-defined items' draw procedures if
the items' rectangles are within the update region.

The DialogSelect, ModalDialog, Alert, StopAlert, NoteAlert, and CautionAlert routines use DrawDialog automatically. If you use GetNewDialog
to create a dialog box but don't use any of these other Dialog Manager routines when handling events in the dialog box, you can use DrawDialog to redraw the contents of the dialog box when it's visible. If the dialog box is invisible, first use the Window Manager procedure ShowWindow and then use DrawDialog.

SEE ALSO
See the chapters "Window Manager" and "Event Manager" in this book for more information on update and activate events for windows. The DrawControls procedure is described in the chapter "Control Manager" in this book. The TEUpdate procedure is described in the chapter "TextEdit" in Inside Macintosh: Text.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 JUL 1996