summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog12
-rw-r--r--generic/tkDecls.h9
-rw-r--r--generic/tkIntDecls.h4
-rw-r--r--generic/tkPlatDecls.h4
-rw-r--r--win/tkWinEmbed.c37
-rw-r--r--win/tkWinSend.c12
6 files changed, 35 insertions, 43 deletions
diff --git a/ChangeLog b/ChangeLog
index 46b00ae..5d16c9b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2008-04-08 Kevin Kenny <kennykb@acm.org>
+
+ * tkDecls.h: Reverted das's change of Tk's stubs pointers
+ * tkIntDecls.h: from 'extern' to 'EXTERN'. Since the stubs pointer
+ * tkPlatDecls.h: is always linked statically, its wrong to import
+ or export it from a DLL, and the change causes
+ trouble for extensions that build with -DUSE_TK_STUBS.
+ * tkWinEmbed.c: Removed #if 0 code. Trust the revision control system,
+ if you need it again, you can find it.
+ * tkWinSend.c: Added conditional compilation to silence several
+ compiler warnings.
+
2008-04-07 Jeff Hobbs <jeffh@ActiveState.com>
* generic/tkWindow.c (Initialize): fix double-free on Tk_ParseArgv
diff --git a/generic/tkDecls.h b/generic/tkDecls.h
index c0e0ac5..250a3e0 100644
--- a/generic/tkDecls.h
+++ b/generic/tkDecls.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: tkDecls.h,v 1.32 2008/04/02 21:32:32 das Exp $
+ * RCS: @(#) $Id: tkDecls.h,v 1.33 2008/04/08 03:28:04 kennykb Exp $
*/
#ifndef _TKDECLS
@@ -1983,7 +1983,12 @@ typedef struct TkStubs {
} TkStubs;
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
-EXTERN CONST TkStubs *tkStubsPtr;
+/*
+ * The following declaration has to be 'extern', not EXTERN. The
+ * stubs pointer is always static-linked, and never exported from
+ * a DLL.
+ */
+extern const TkStubs *tkStubsPtr;
#endif /* defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) */
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
diff --git a/generic/tkIntDecls.h b/generic/tkIntDecls.h
index 3dc3cbf..d5f1266 100644
--- a/generic/tkIntDecls.h
+++ b/generic/tkIntDecls.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: tkIntDecls.h,v 1.33 2008/04/02 21:32:32 das Exp $
+ * RCS: @(#) $Id: tkIntDecls.h,v 1.34 2008/04/08 03:28:05 kennykb Exp $
*/
#ifndef _TKINTDECLS
@@ -1223,7 +1223,7 @@ typedef struct TkIntStubs {
} TkIntStubs;
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
-EXTERN CONST TkIntStubs *tkIntStubsPtr;
+extern CONST TkIntStubs *tkIntStubsPtr;
#endif /* defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) */
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
diff --git a/generic/tkPlatDecls.h b/generic/tkPlatDecls.h
index d1219cc..d2cc339 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.17 2008/04/02 21:32:33 das Exp $
+ * RCS: @(#) $Id: tkPlatDecls.h,v 1.18 2008/04/08 03:28:05 kennykb Exp $
*/
#ifndef _TKPLATDECLS
@@ -157,7 +157,7 @@ typedef struct TkPlatStubs {
} TkPlatStubs;
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
-EXTERN CONST TkPlatStubs *tkPlatStubsPtr;
+extern CONST TkPlatStubs *tkPlatStubsPtr;
#endif /* defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS) */
#if defined(USE_TK_STUBS) && !defined(USE_TK_STUB_PROCS)
diff --git a/win/tkWinEmbed.c b/win/tkWinEmbed.c
index 63e837a..80b1204 100644
--- a/win/tkWinEmbed.c
+++ b/win/tkWinEmbed.c
@@ -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: tkWinEmbed.c,v 1.33 2007/12/13 15:28:55 dgp Exp $
+ * RCS: @(#) $Id: tkWinEmbed.c,v 1.34 2008/04/08 03:28:05 kennykb Exp $
*/
#include "tkWinInt.h"
@@ -45,8 +45,6 @@ static Tcl_ThreadDataKey dataKey;
static void ContainerEventProc(ClientData clientData,
XEvent *eventPtr);
-static void EmbeddedEventProc(ClientData clientData,
- XEvent *eventPtr);
static void EmbedGeometryRequest(Container *containerPtr,
int width, int height);
static void EmbedWindowDeleted(TkWindow *winPtr);
@@ -389,39 +387,6 @@ TkpMakeContainer(
ContainerEventProc, (ClientData) containerPtr);
}
-#if 0
-/*
- *----------------------------------------------------------------------
- *
- * EmbeddedEventProc --
- *
- * This procedure is invoked by the Tk event dispatcher when various
- * useful events are received for a window that is embedded in another
- * application.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Our internal state gets cleaned up when an embedded window is
- * destroyed.
- *
- *----------------------------------------------------------------------
- */
-
-static void
-EmbeddedEventProc(
- ClientData clientData, /* Token for container window. */
- XEvent *eventPtr) /* ResizeRequest event. */
-{
- TkWindow *winPtr = (TkWindow *) clientData;
-
- if (eventPtr->type == DestroyNotify) {
- EmbedWindowDeleted(winPtr);
- }
-}
-#endif
-
/*
*----------------------------------------------------------------------
*
diff --git a/win/tkWinSend.c b/win/tkWinSend.c
index 086d55e..ac94c0b 100644
--- a/win/tkWinSend.c
+++ b/win/tkWinSend.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: tkWinSend.c,v 1.15 2007/12/13 15:28:56 dgp Exp $
+ * RCS: @(#) $Id: tkWinSend.c,v 1.16 2008/04/08 03:28:05 kennykb Exp $
*/
#include "tkInt.h"
@@ -63,13 +63,17 @@ static Tcl_ThreadDataKey dataKey;
* Functions internal to this file.
*/
+#ifdef TK_SEND_ENABLED_ON_WINDOWS
static void CmdDeleteProc(ClientData clientData);
static void InterpDeleteProc(ClientData clientData,
Tcl_Interp *interp);
+#endif
static void RevokeObjectRegistration(RegisteredInterp *riPtr);
static HRESULT BuildMoniker(const char *name, LPMONIKER *pmk);
+#ifdef TK_SEND_ENABLED_ON_WINDOWS
static HRESULT RegisterInterp(const char *name,
RegisteredInterp *riPtr);
+#endif
static int FindInterpreterObject(Tcl_Interp *interp,
const char *name, LPDISPATCH *ppdisp);
static int Send(LPDISPATCH pdispInterp, Tcl_Interp *interp,
@@ -471,6 +475,7 @@ FindInterpreterObject(
*--------------------------------------------------------------
*/
+#ifdef TK_SEND_ENABLED_ON_WINDOWS
static void
CmdDeleteProc(
ClientData clientData)
@@ -506,6 +511,7 @@ CmdDeleteProc(
ckfree(clientData);
}
+#endif
/*
*--------------------------------------------------------------
@@ -568,6 +574,7 @@ RevokeObjectRegistration(
* ----------------------------------------------------------------------
*/
+#ifdef TK_SEND_ENABLED_ON_WINDOWS
static void
InterpDeleteProc(
ClientData clientData,
@@ -575,6 +582,7 @@ InterpDeleteProc(
{
CoUninitialize();
}
+#endif
/*
* ----------------------------------------------------------------------
@@ -638,6 +646,7 @@ BuildMoniker(
* ----------------------------------------------------------------------
*/
+#ifdef TK_SEND_ENABLED_ON_WINDOWS
static HRESULT
RegisterInterp(
const char *name,
@@ -694,6 +703,7 @@ RegisterInterp(
Tcl_DStringFree(&dString);
return hr;
}
+#endif
/*
* ----------------------------------------------------------------------