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


Manipulating Items in Alert and Dialog Boxes

In many cases, you won't have to make any changes to alert or dialog boxes after you define them in the resource file. If you do need to make changes, use the Dialog Manager routines described in this section.

For most item manipulation, first call the GetDialogItem procedure to get the information about the item. You can then use other routines to manipulate that item. Use the SetDialogItem procedure if you use any of these other routines to change the item. You must also use SetDialogItem to install any of your own application-defined draw procedures. If you use SetDialogItem, make the dialog box initially invisible, change the item as appropriate, then make the dialog box visible by using the Window Manager procedure ShowWindow. (For information about manipulating text in an
alert box or a dialog box, see "Handling Text in Alert and Dialog Boxes" beginning on page 6-122.)

You can dynamically add items to and remove items from a dialog box by using the AppendDITL and ShortenDITL procedures. These procedures are especially useful
if you share a single item list resource among multiple dialog boxes, because you can then use AppendDITL or ShortenDITL to add or remove items as appropriate for individual dialog boxes. You typically make such dialog boxes invisible, use the AppendDITL and ShortenDITL procedures as appropriate, then make the dialog
boxes visible by using the Window Manager procedure ShowWindow.


Subtopics
GetDialogItem
SetDialogItem
HideDialogItem
ShowDialogItem
FindDialogItem
AppendDITL
ShortenDITL
CountDITL

Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 JUL 1996