Set the alert default button using the CPCarriageReturnCharacter key equivalent to match the recent Cappuccino change for default buttons.

This commit is contained in:
Alexander Ljungberg authored and Ross Boucher committed 2010-06-19 15:42:29 -07:00
1 parent 12a49d0ee1
commit 4b86115d30
1 file changed
+3 -1
+3 -1
View File
@@ -301,9 +301,11 @@ var CPAlertWarningImage,
[[_alertPanel contentView] addSubview:button];
if (_buttonCount == 0)
[_alertPanel setDefaultButton:button];
[button setKeyEquivalent:CPCarriageReturnCharacter];
else if ([title lowercaseString] === "cancel")
[button setKeyEquivalent:CPEscapeFunctionKey];
else
[button setKeyEquivalent:nil];
_buttonCount++;
[_buttons addObject:button];