Types of Alerts
There are two types of alerts, standard and caution. Most alerts should be standard alerts, which display the application icon of the current application, as shown in Figure 1.
Use a caution alert only to warn the user when a possible side effect of the current task is the inadvertent destruction of data. A caution alert displays a caution icon badged with application icon, as shown in Figure 2.
How you specify the alert type varies according to programmatic interface:
setAlertStyle:to an NSAlert object with an argument of
NSInformationalAlertStyleto specify a standard alert. Send the same message with an argument of
NSCriticalAlertStyleto specify a caution alert.
Functional API. Use the
NSBeginAlertSheetfunction to display a standard alert and
NSBeginCriticalAlertSheetto display a caution alert.
Caution alerts should be used only as specified in the “Alerts” in OS X Human Interface Guidelines section of Apple Human Interface Guidelines.
© 2002, 2009 Apple Inc. All Rights Reserved. (Last updated: 2009-05-04)