• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CFUserNotificationDisplayAlert return value error?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CFUserNotificationDisplayAlert return value error?


  • Subject: Re: CFUserNotificationDisplayAlert return value error?
  • From: Douglas Davidson <email@hidden>
  • Date: Tue, 18 Apr 2006 13:36:51 -0700


On Apr 18, 2006, at 1:16 PM, Peter Hull wrote:

It seems like the implementation of  CFUserNotificationDisplayAlert
doesn't match its documentation.


Here is a little test program you can use. If the user hits "Default", the response flags should be 0. If the user hits "Alternate", the response flags should be 1. If the user hits "Other", the response flags should be 2. If the user hits escape or cmd-., or if the alert times out without a response, the response flags should be 3. The return value should be non-zero only if there is some unexpected error along the way. This is the behavior on 10.4; the behavior on 10.2 should be similar, with the possible exception of the escape and cmd-. handling.


Douglas Davidson

#include <CoreFoundation/CoreFoundation.h>

main() {
CFOptionFlags responseFlags;
SInt32 retval = CFUserNotificationDisplayAlert(60.0, 0, NULL, NULL, NULL, CFSTR("Alert Header"), CFSTR("Alert message."), CFSTR ("Default"), CFSTR("Alternate"), CFSTR("Other"), &responseFlags);
printf("retval 0x%x responseFlags 0x%x\n", retval, responseFlags);
}



_______________________________________________ Do not post admin requests to the list. They will be ignored. Cocoa-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Fwd: CFUserNotificationDisplayAlert return value error? (From: "Peter Hull" <email@hidden>)

  • Prev by Date: Re: Interface Builder Date Localization
  • Next by Date: Re: What happens to my German strings?
  • Previous by thread: Fwd: CFUserNotificationDisplayAlert return value error?
  • Next by thread: [Q] COM and dynamic link library?
  • Index(es):
    • Date
    • Thread