summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2016-01-23 21:09:17 (GMT)
committerdgp <dgp@users.sourceforge.net>2016-01-23 21:09:17 (GMT)
commitff8b5479baab369fa6163bf42b9928dcb482261f (patch)
tree23038658da225431345cd584e9449094f7083e35
parent10be4df79f97808bfedd7ac58d6e44e04a221e65 (diff)
parentaafc31a89b188a589cc256a1f62bb80b2f053a2b (diff)
downloadtk-ff8b5479baab369fa6163bf42b9928dcb482261f.zip
tk-ff8b5479baab369fa6163bf42b9928dcb482261f.tar.gz
tk-ff8b5479baab369fa6163bf42b9928dcb482261f.tar.bz2
merge 8.5
-rw-r--r--macosx/tkMacOSXDialog.c7
-rw-r--r--tests/font.test1
2 files changed, 6 insertions, 2 deletions
diff --git a/macosx/tkMacOSXDialog.c b/macosx/tkMacOSXDialog.c
index 67f17be..0f7ef3a 100644
--- a/macosx/tkMacOSXDialog.c
+++ b/macosx/tkMacOSXDialog.c
@@ -395,10 +395,12 @@ Tk_GetOpenFileObjCmd(
NSMutableArray *fileTypes = nil;
NSOpenPanel *panel = [NSOpenPanel openPanel];
NSInteger modalReturnCode = modalError;
+#if MAC_OS_X_VERSION_MIN_REQUIRED < 1060
+ BOOL parentIsKey = NO;
+#endif
TkInitFileFilters(&fl);
for (i = 1; i < objc; i += 2) {
- BOOL parentIsKey = NO;
if (Tcl_GetIndexFromObjStruct(interp, objv[i], openOptionStrings,
sizeof(char *), "option", TCL_EXACT, &index) != TCL_OK) {
goto end;
@@ -598,10 +600,11 @@ Tk_GetSaveFileObjCmd(
NSMutableArray *fileTypes = nil;
NSSavePanel *panel = [NSSavePanel savePanel];
NSInteger modalReturnCode = modalError;
+ BOOL parentIsKey = NO;
TkInitFileFilters(&fl);
for (i = 1; i < objc; i += 2) {
- BOOL parentIsKey = NO;
+ parentIsKey = NO;
if (Tcl_GetIndexFromObjStruct(interp, objv[i], saveOptionStrings,
sizeof(char *), "option", TCL_EXACT, &index) != TCL_OK) {
goto end;
diff --git a/tests/font.test b/tests/font.test
index 9ed24dc..2defb29 100644
--- a/tests/font.test
+++ b/tests/font.test
@@ -1162,6 +1162,7 @@ test font-33.1 {Tk_TextWidth procedure} {
test font-34.1 {ConfigAttributesObj procedure: arguments} {
# (Tcl_GetIndexFromObj() != TCL_OK)
+ set x {}
setup
list [catch {font create xyz -xyz} msg] $msg
} {1 {bad option "-xyz": must be -family, -size, -weight, -slant, -underline, or -overstrike}}