summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordas <das>2006-12-01 07:13:00 (GMT)
committerdas <das>2006-12-01 07:13:00 (GMT)
commit2bb1590cb848832772cfdc9474090903d4790aa2 (patch)
tree1727761a632d5ce53615cea53c7638df2ee13446
parent9c00f95076d88ab3a267b232e9ab714c95287ef0 (diff)
downloadtk-2bb1590cb848832772cfdc9474090903d4790aa2.zip
tk-2bb1590cb848832772cfdc9474090903d4790aa2.tar.gz
tk-2bb1590cb848832772cfdc9474090903d4790aa2.tar.bz2
* macosx/tkMacOSXDialog.c (Tk_MessageBoxObjCmd): fix inability to use
buttons with standard Escape key binding as -default button (reported on tcl-mac by Hans-Christoph Steiner).
-rw-r--r--ChangeLog4
-rw-r--r--macosx/tkMacOSXDialog.c5
2 files changed, 8 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 32c6a90..a534cea 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
2006-11-30 Daniel Steffen <das@users.sourceforge.net>
+ * macosx/tkMacOSXDialog.c (Tk_MessageBoxObjCmd): fix inability to use
+ buttons with standard Escape key binding as -default button (reported
+ on tcl-mac by Hans-Christoph Steiner).
+
* macosx/tkMacOSXWm.c (WmAttributesCmd): fix getting [wm attr -alpha].
[Bug 1581932]
diff --git a/macosx/tkMacOSXDialog.c b/macosx/tkMacOSXDialog.c
index 5880b48..8d0b7c5 100644
--- a/macosx/tkMacOSXDialog.c
+++ b/macosx/tkMacOSXDialog.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMacOSXDialog.c,v 1.20 2006/04/11 12:05:50 das Exp $
+ * RCS: @(#) $Id: tkMacOSXDialog.c,v 1.21 2006/12/01 07:13:00 das Exp $
*/
#include "tkMacOSXInt.h"
@@ -1535,6 +1535,9 @@ Tk_MessageBoxObjCmd(
goto end;
}
paramCFStringRec.defaultButton = defaultNativeButtonIndex;
+ if (paramCFStringRec.cancelButton == defaultNativeButtonIndex) {
+ paramCFStringRec.cancelButton = 0;
+ }
}
SetThemeCursor(kThemeArrowCursor);