cqlinx 发表于 2015-12-31 14:46:51

Using Alert Panels(Chapter 15 of Cocoa Programming for Mac OS X)

  The NSRunAlertPanel() function returns anint that indicates which button the userclicked. There are global variables for these constants:NSAlertDefaultReturn, NSAlertAlternateReturn, andNSAlertOtherReturn.


int NSRunAlertPanel(NSString *title, NSString *msg,                NSString *defaultButton, NSString *alternateButton,            NSString *otherButton, ...);  
页: [1]
查看完整版本: Using Alert Panels(Chapter 15 of Cocoa Programming for Mac OS X)