summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordas <das>2006-02-09 19:08:50 (GMT)
committerdas <das>2006-02-09 19:08:50 (GMT)
commit3e97de678ab8cbce3e00a0a396d89ea65ffc5b55 (patch)
tree7b697aaeb41435d2223cd2cce400b3e8c002e89f
parentdcbd07d255f872ce6907e3af83c6fd3b52f30e05 (diff)
downloadtk-3e97de678ab8cbce3e00a0a396d89ea65ffc5b55.zip
tk-3e97de678ab8cbce3e00a0a396d89ea65ffc5b55.tar.gz
tk-3e97de678ab8cbce3e00a0a396d89ea65ffc5b55.tar.bz2
* generic/tk.decls: fix signature of TkMacOSXInvalClipRgns
* generic/tkPlatDecls.h: to use Tk_Window instead of internal * macosx/tkMacOSXSubwindows.c: type TkWindow (which led to any include * macosx/tkMacOSXWindowEvent.c: of public header tkMacOSX.h requiring * macosx/tkMacOSXWm.c: prior include of tkInt.h). * generic/tk.h: move TkAqua specific REDO_KEYSYM_LOOKUP define * macosx/tkMacOSXPort.h: out of tk.h into platform header.
-rw-r--r--ChangeLog11
-rw-r--r--generic/tk.decls4
-rw-r--r--generic/tk.h13
-rw-r--r--generic/tkPlatDecls.h6
-rw-r--r--macosx/tkMacOSXPort.h9
-rw-r--r--macosx/tkMacOSXSubwindows.c31
-rw-r--r--macosx/tkMacOSXWindowEvent.c4
-rw-r--r--macosx/tkMacOSXWm.c6
8 files changed, 46 insertions, 38 deletions
diff --git a/ChangeLog b/ChangeLog
index b472eb8..c9e69fd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+2006-02-09 Daniel Steffen <das@users.sourceforge.net>
+
+ * generic/tk.decls: fix signature of TkMacOSXInvalClipRgns
+ * generic/tkPlatDecls.h: to use Tk_Window instead of internal
+ * macosx/tkMacOSXSubwindows.c: type TkWindow (which led to any include
+ * macosx/tkMacOSXWindowEvent.c: of public header tkMacOSX.h requiring
+ * macosx/tkMacOSXWm.c: prior include of tkInt.h).
+
+ * generic/tk.h: move TkAqua specific REDO_KEYSYM_LOOKUP define
+ * macosx/tkMacOSXPort.h: out of tk.h into platform header.
+
2006-01-31 Donal K. Fellows <dkf@users.sf.net>
* library/bgerror.tcl (::tk::dialog::error::bgerror): Finish the
diff --git a/generic/tk.decls b/generic/tk.decls
index c1151bf..98dfcd9 100644
--- a/generic/tk.decls
+++ b/generic/tk.decls
@@ -11,7 +11,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: tk.decls,v 1.27 2005/05/27 23:14:28 dkf Exp $
+# RCS: @(#) $Id: tk.decls,v 1.28 2006/02/09 19:08:51 das Exp $
library tk
@@ -1338,7 +1338,7 @@ declare 5 aqua {
}
declare 6 aqua {
- void TkMacOSXInvalClipRgns (TkWindow *winPtr)
+ void TkMacOSXInvalClipRgns (Tk_Window tkwin)
}
declare 7 aqua {
diff --git a/generic/tk.h b/generic/tk.h
index 831c905..afc6032 100644
--- a/generic/tk.h
+++ b/generic/tk.h
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tk.h,v 1.85 2005/11/27 02:36:13 das Exp $
+ * RCS: @(#) $Id: tk.h,v 1.86 2006/02/09 19:08:51 das Exp $
*/
#ifndef _TK
@@ -55,17 +55,6 @@ extern "C" {
#define TK_VERSION "8.5"
#define TK_PATCH_LEVEL "8.5a4"
-/*
- * The following definitions set up the proper options for Macintosh
- * compilers. We use this method because there is no autoconf equivalent.
- */
-
-#if defined(MAC_OSX_TK)
-# ifndef REDO_KEYSYM_LOOKUP
-# define REDO_KEYSYM_LOOKUP
-# endif
-#endif
-
#ifndef _TCL
# include <tcl.h>
# if (TCL_MAJOR_VERSION != 8) || (TCL_MINOR_VERSION != 5)
diff --git a/generic/tkPlatDecls.h b/generic/tkPlatDecls.h
index db6719d..9b39cff 100644
--- a/generic/tkPlatDecls.h
+++ b/generic/tkPlatDecls.h
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkPlatDecls.h,v 1.11 2005/05/29 06:47:04 das Exp $
+ * RCS: @(#) $Id: tkPlatDecls.h,v 1.12 2006/02/09 19:08:51 das Exp $
*/
#ifndef _TKPLATDECLS
@@ -108,7 +108,7 @@ EXTERN void TkGenWMConfigureEvent _ANSI_ARGS_((Tk_Window tkwin,
#ifndef TkMacOSXInvalClipRgns_TCL_DECLARED
#define TkMacOSXInvalClipRgns_TCL_DECLARED
/* 6 */
-EXTERN void TkMacOSXInvalClipRgns _ANSI_ARGS_((TkWindow * winPtr));
+EXTERN void TkMacOSXInvalClipRgns _ANSI_ARGS_((Tk_Window tkwin));
#endif
#ifndef TkMacOSXGetDrawablePort_TCL_DECLARED
#define TkMacOSXGetDrawablePort_TCL_DECLARED
@@ -153,7 +153,7 @@ typedef struct TkPlatStubs {
void (*tkMacOSXInitMenus) _ANSI_ARGS_((Tcl_Interp * interp)); /* 3 */
void (*tkMacOSXInitAppleEvents) _ANSI_ARGS_((Tcl_Interp * interp)); /* 4 */
void (*tkGenWMConfigureEvent) _ANSI_ARGS_((Tk_Window tkwin, int x, int y, int width, int height, int flags)); /* 5 */
- void (*tkMacOSXInvalClipRgns) _ANSI_ARGS_((TkWindow * winPtr)); /* 6 */
+ void (*tkMacOSXInvalClipRgns) _ANSI_ARGS_((Tk_Window tkwin)); /* 6 */
GWorldPtr (*tkMacOSXGetDrawablePort) _ANSI_ARGS_((Drawable drawable)); /* 7 */
ControlRef (*tkMacOSXGetRootControl) _ANSI_ARGS_((Drawable drawable)); /* 8 */
void (*tk_MacOSXSetupTkNotifier) _ANSI_ARGS_((void)); /* 9 */
diff --git a/macosx/tkMacOSXPort.h b/macosx/tkMacOSXPort.h
index 09a5cf3..c43fcce 100644
--- a/macosx/tkMacOSXPort.h
+++ b/macosx/tkMacOSXPort.h
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMacOSXPort.h,v 1.6 2005/11/27 02:36:15 das Exp $
+ * RCS: @(#) $Id: tkMacOSXPort.h,v 1.7 2006/02/09 19:08:51 das Exp $
*/
#ifndef _TKMACPORT
@@ -145,6 +145,13 @@ extern int strcasecmp _ANSI_ARGS_((CONST char *s1,
extern int strncasecmp _ANSI_ARGS_((CONST char *s1,
CONST char *s2, size_t n));
#endif
+
+/*
+ * The following define causes Tk to use its internal keysym hash table
+ */
+
+#define REDO_KEYSYM_LOOKUP
+
/*
* Defines for X functions that are used by Tk but are treated as
* no-op functions on the Macintosh.
diff --git a/macosx/tkMacOSXSubwindows.c b/macosx/tkMacOSXSubwindows.c
index f470327..3fcee67 100644
--- a/macosx/tkMacOSXSubwindows.c
+++ b/macosx/tkMacOSXSubwindows.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: tkMacOSXSubwindows.c,v 1.10 2005/11/27 02:36:15 das Exp $
+ * RCS: @(#) $Id: tkMacOSXSubwindows.c,v 1.11 2006/02/09 19:08:50 das Exp $
*/
#include "tkInt.h"
@@ -144,7 +144,7 @@ XDestroyWindow(
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW);
}
if (macWin->winPtr->parentPtr != NULL) {
- TkMacOSXInvalClipRgns(macWin->winPtr->parentPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr->parentPtr);
}
DisposeRgn(macWin->clipRgn);
DisposeRgn(macWin->aboveClipRgn);
@@ -279,7 +279,7 @@ XMapWindow(
event.xmap.override_redirect = macWin->winPtr->atts.override_redirect;
Tk_QueueWindowEvent(&event, TCL_QUEUE_TAIL);
} else {
- TkMacOSXInvalClipRgns(macWin->winPtr->parentPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr->parentPtr);
}
/*
@@ -357,7 +357,7 @@ XUnmapWindow(
*/
SetGWorld(destPort, NULL);
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW); /* TODO: may not be valid */
- TkMacOSXInvalClipRgns(macWin->winPtr->parentPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr->parentPtr);
}
}
@@ -407,7 +407,7 @@ XResizeWindow(
SizeWindow(GetWindowFromPort(destPort),
(short) width, (short) height, false);
TkMacOSXInvalidateWindow(macWin, TK_WINDOW_ONLY);
- TkMacOSXInvalClipRgns(macWin->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr);
}
} else {
int deltaX, deltaY;
@@ -425,7 +425,7 @@ XResizeWindow(
if (havePort) {
SetPort(destPort);
- TkMacOSXInvalClipRgns(macParent->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr);
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW);
}
deltaX = macParent->xOff +
@@ -459,7 +459,7 @@ XResizeWindow(
if (havePort) {
SetPort(destPort);
- TkMacOSXInvalClipRgns(macParent->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr);
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW);
}
deltaX = - macWin->xOff;
@@ -563,7 +563,7 @@ XMoveResizeWindow(
/* TODO: is the following right? */
TkMacOSXInvalidateWindow(macWin, TK_WINDOW_ONLY);
- TkMacOSXInvalClipRgns(macWin->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr);
}
} else {
int deltaX, deltaY, parentBorderwidth;
@@ -598,7 +598,7 @@ XMoveResizeWindow(
if (havePort) {
SetPort( destPort);
- TkMacOSXInvalClipRgns(macParent->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr);
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW);
}
@@ -674,7 +674,7 @@ XMoveWindow(
/* TODO: is the following right? */
TkMacOSXInvalidateWindow(macWin, TK_WINDOW_ONLY);
- TkMacOSXInvalClipRgns(macWin->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macWin->winPtr);
}
} else {
int deltaX, deltaY, parentBorderwidth;
@@ -708,7 +708,7 @@ XMoveWindow(
if (havePort) {
SetPort(destPort);
- TkMacOSXInvalClipRgns(macParent->winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) macParent->winPtr);
TkMacOSXInvalidateWindow(macWin, TK_PARENT_WINDOW);
}
@@ -857,7 +857,7 @@ XConfigureWindow(
destPort = TkMacOSXGetDrawablePort(w);
if (destPort != NULL) {
SetPort( destPort);
- TkMacOSXInvalClipRgns(winPtr->parentPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) winPtr->parentPtr);
TkMacOSXWinBounds(winPtr, &bounds);
InvalWindowRect(GetWindowFromPort(destPort),&bounds);
}
@@ -1237,8 +1237,9 @@ TkMacOSXGetRootControl(
void
TkMacOSXInvalClipRgns(
- TkWindow *winPtr)
+ Tk_Window tkwin)
{
+ TkWindow *winPtr = (TkWindow *) tkwin;
TkWindow *childPtr;
/*
@@ -1258,7 +1259,7 @@ TkMacOSXInvalClipRgns(
childPtr = winPtr->childList;
while (childPtr != NULL) {
if (!Tk_IsTopLevel(childPtr) && Tk_IsMapped(childPtr)) {
- TkMacOSXInvalClipRgns(childPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) childPtr);
}
childPtr = childPtr->nextPtr;
}
@@ -1271,7 +1272,7 @@ TkMacOSXInvalClipRgns(
childPtr = TkpGetOtherWindow(winPtr);
if (childPtr != NULL && Tk_IsMapped(childPtr)) {
- TkMacOSXInvalClipRgns(childPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) childPtr);
}
/*
diff --git a/macosx/tkMacOSXWindowEvent.c b/macosx/tkMacOSXWindowEvent.c
index 0fa938b..8b84b69 100644
--- a/macosx/tkMacOSXWindowEvent.c
+++ b/macosx/tkMacOSXWindowEvent.c
@@ -54,7 +54,7 @@
* software in accordance with the terms specified in this
* license.
*
- * RCS: @(#) $Id: tkMacOSXWindowEvent.c,v 1.9 2005/12/01 06:24:16 hobbs Exp $
+ * RCS: @(#) $Id: tkMacOSXWindowEvent.c,v 1.10 2006/02/09 19:08:50 das Exp $
*/
#include "tkMacOSXInt.h"
@@ -623,7 +623,7 @@ TkGenWMConfigureEvent(
winPtr->changes.y = y;
winPtr->changes.width = width;
winPtr->changes.height = height;
- TkMacOSXInvalClipRgns(winPtr);
+ TkMacOSXInvalClipRgns(tkwin);
}
/*
diff --git a/macosx/tkMacOSXWm.c b/macosx/tkMacOSXWm.c
index 0a5fd22..3cc0444 100644
--- a/macosx/tkMacOSXWm.c
+++ b/macosx/tkMacOSXWm.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMacOSXWm.c,v 1.21 2005/11/27 02:36:15 das Exp $
+ * RCS: @(#) $Id: tkMacOSXWm.c,v 1.22 2006/02/09 19:08:50 das Exp $
*/
#include <Carbon/Carbon.h>
@@ -4501,7 +4501,7 @@ TkMacOSXGrowToplevel(
LoWord(growResult), HiWord(growResult), true);
SetPort( GetWindowPort(whichWindow));
InvalWindowRect(whichWindow,&portRect); /* TODO: may not be needed */
- TkMacOSXInvalClipRgns(winPtr);
+ TkMacOSXInvalClipRgns((Tk_Window) winPtr);
TkGenWMConfigureEvent((Tk_Window) winPtr, -1, -1,
(int) LoWord(growResult), (int) HiWord(growResult),
TK_SIZE_CHANGED);
@@ -4690,7 +4690,7 @@ TkMacOSXZoomToplevel(
ZoomWindow(whichWindow, zoomPart, false);
InvalWindowRect(whichWindow,&portRect);
- TkMacOSXInvalClipRgns((TkWindow *) tkwin);
+ TkMacOSXInvalClipRgns(tkwin);
LocalToGlobal(&location);
TkMacOSXWindowOffset(whichWindow, &xOffset, &yOffset);