summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXDialog.c
diff options
context:
space:
mode:
authordas <das>2007-06-23 00:26:32 (GMT)
committerdas <das>2007-06-23 00:26:32 (GMT)
commitfa02a33e1916c8b6d2ba0318fc8b74f42e069808 (patch)
tree8196e9c9ba9ea5cd9268de7f21da64e16032d2d5 /macosx/tkMacOSXDialog.c
parent4e2bd974f22a0d3872a1939e38a365d9a62e14e3 (diff)
downloadtk-fa02a33e1916c8b6d2ba0318fc8b74f42e069808.zip
tk-fa02a33e1916c8b6d2ba0318fc8b74f42e069808.tar.gz
tk-fa02a33e1916c8b6d2ba0318fc8b74f42e069808.tar.bz2
* macosx/tkMacOSXXStubs.c (XCreateImage, DestroyImage): correct XImage
bytes_per_line/bitmap_pad calculations and endianness setting; free image data and XImage structure at destruction; formatting cleanup. * macosx/tkMacOSXDialog.c (NavServicesGetFile): disable app-modal sheet variant of nav dialog on OS versions where it causes problems.
Diffstat (limited to 'macosx/tkMacOSXDialog.c')
-rw-r--r--macosx/tkMacOSXDialog.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/macosx/tkMacOSXDialog.c b/macosx/tkMacOSXDialog.c
index 14117ac..f8be9d0 100644
--- a/macosx/tkMacOSXDialog.c
+++ b/macosx/tkMacOSXDialog.c
@@ -10,7 +10,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.25 2007/05/09 12:55:15 das Exp $
+ * RCS: @(#) $Id: tkMacOSXDialog.c,v 1.26 2007/06/23 00:26:32 das Exp $
*/
#include "tkMacOSXInt.h"
@@ -776,10 +776,17 @@ NavServicesGetFile(
TkMacOSXHostToplevelExists(parent)) {
options.parentWindow = GetWindowFromPort(TkMacOSXGetDrawablePort(
Tk_WindowId(parent)));
- if (options.parentWindow) {
- options.modality = kWindowModalityWindowModal;
- data.sheet = 1;
- }
+ TK_IF_HI_TOOLBOX (5,
+ /*
+ * Impossible to modify dialog modality with the Cocoa-based
+ * NavServices implementation.
+ */
+ ) TK_ELSE_HI_TOOLBOX (5,
+ if (options.parentWindow) {
+ options.modality = kWindowModalityWindowModal;
+ data.sheet = 1;
+ }
+ ) TK_ENDIF
}
/*