summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <jan.nijtmans@noemail.net>2012-05-24 21:15:46 (GMT)
committerjan.nijtmans <jan.nijtmans@noemail.net>2012-05-24 21:15:46 (GMT)
commit668b781d3f1f94884719b36eff9d3e04c276afb0 (patch)
tree209933d2accf8feb64d481f548a0029cae195009
parent5668666cb48b5738cf6cfb74b80ae1240f5ea191 (diff)
parent5228f1801569ac4b5a91362a71f20302b2f7b712 (diff)
downloadtk-668b781d3f1f94884719b36eff9d3e04c276afb0.zip
tk-668b781d3f1f94884719b36eff9d3e04c276afb0.tar.gz
tk-668b781d3f1f94884719b36eff9d3e04c276afb0.tar.bz2
Change XSetCommand signature to match Xorg, needed for Cygwin
FossilOrigin-Name: 4a5604149cb82977530a21972d1969429938d52e
-rw-r--r--ChangeLog9
-rw-r--r--generic/tkInt.decls2
-rw-r--r--generic/tkIntDecls.h6
-rw-r--r--generic/tkIntXlibDecls.h11
-rw-r--r--generic/tkPlatDecls.h6
-rw-r--r--generic/tkStubInit.c10
-rw-r--r--win/Makefile.in6
-rw-r--r--win/stubs.c2
-rw-r--r--win/tkWinWm.c2
9 files changed, 30 insertions, 24 deletions
diff --git a/ChangeLog b/ChangeLog
index f2059ce..3e4aa5d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,13 @@
+2012-05-24 Jan Nijtmans <nijtmans@users.sf.net>
+
+ * win/stubs.c: Change XSetCommand signature to match Xorg,
+ * win/tkWinWm.c: needed for Cygwin.
+ * generic/tkInt.decls
+ * generic/tk*Decls.h: re-generated
+
2012-05-09 Jan Nijtmans <nijtmans@users.sf.net>
- * win/tkWinWm.c: Change TkpWmSetState signature to match UNIX,
+ * win/tkWinWm.c: Change TkpWmSetState signature to match Xorg,
* generic/tkInt.decls: needed for Cygwin. (not needed for Mac)
* generic/tkIntPlatDeclsDecls.h:
* generic/tkWindow.c: Don't check for cygwin in win32 static build.
diff --git a/generic/tkInt.decls b/generic/tkInt.decls
index b18f6f1..33921ba 100644
--- a/generic/tkInt.decls
+++ b/generic/tkInt.decls
@@ -1199,7 +1199,7 @@ declare 61 win {
Status XSendEvent(Display *d, Window w, Bool b, long l, XEvent *x)
}
declare 62 win {
- void XSetCommand(Display *d, Window w, const char **c, int i)
+ void XSetCommand(Display *d, Window w, char **c, int i)
}
declare 63 win {
void XSetIconName(Display *d, Window w, _Xconst char *c)
diff --git a/generic/tkIntDecls.h b/generic/tkIntDecls.h
index 5fe8a56..acb9639 100644
--- a/generic/tkIntDecls.h
+++ b/generic/tkIntDecls.h
@@ -1091,7 +1091,7 @@ typedef struct TkIntStubs {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
VOID *reserved121;
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
VOID *reserved121;
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
@@ -1101,7 +1101,7 @@ typedef struct TkIntStubs {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
VOID *reserved122;
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
VOID *reserved122;
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
@@ -1112,7 +1112,7 @@ typedef struct TkIntStubs {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
VOID *reserved124;
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
VOID *reserved124;
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
diff --git a/generic/tkIntXlibDecls.h b/generic/tkIntXlibDecls.h
index bf80342..0bc12e5 100644
--- a/generic/tkIntXlibDecls.h
+++ b/generic/tkIntXlibDecls.h
@@ -32,7 +32,7 @@
* Exported function declarations:
*/
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
#ifndef XSetDashes_TCL_DECLARED
#define XSetDashes_TCL_DECLARED
/* 0 */
@@ -395,8 +395,7 @@ EXTERN Status XSendEvent(Display *d, Window w, Bool b, long l,
#ifndef XSetCommand_TCL_DECLARED
#define XSetCommand_TCL_DECLARED
/* 62 */
-EXTERN void XSetCommand(Display *d, Window w, CONST char **c,
- int i);
+EXTERN void XSetCommand(Display *d, Window w, char **c, int i);
#endif
#ifndef XSetIconName_TCL_DECLARED
#define XSetIconName_TCL_DECLARED
@@ -1193,7 +1192,7 @@ typedef struct TkIntXlibStubs {
int magic;
struct TkIntXlibStubHooks *hooks;
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
void (*xSetDashes) (Display *display, GC gc, int dash_offset, _Xconst char *dash_list, int n); /* 0 */
XModifierKeymap * (*xGetModifierMapping) (Display *d); /* 1 */
XImage * (*xCreateImage) (Display *d, Visual *v, unsigned int ui1, int i1, int i2, char *cp, unsigned int ui2, unsigned int ui3, int i3, int i4); /* 2 */
@@ -1256,7 +1255,7 @@ typedef struct TkIntXlibStubs {
void (*xResizeWindow) (Display *d, Window w, unsigned int ui1, unsigned int ui2); /* 59 */
void (*xSelectInput) (Display *d, Window w, long l); /* 60 */
Status (*xSendEvent) (Display *d, Window w, Bool b, long l, XEvent *x); /* 61 */
- void (*xSetCommand) (Display *d, Window w, CONST char **c, int i); /* 62 */
+ void (*xSetCommand) (Display *d, Window w, char **c, int i); /* 62 */
void (*xSetIconName) (Display *d, Window w, _Xconst char *c); /* 63 */
void (*xSetInputFocus) (Display *d, Window w, int i, Time t); /* 64 */
void (*xSetSelectionOwner) (Display *d, Atom a, Window w, Time t); /* 65 */
@@ -1412,7 +1411,7 @@ extern TkIntXlibStubs *tkIntXlibStubsPtr;
* Inline function declarations:
*/
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
#ifndef XSetDashes
#define XSetDashes \
(tkIntXlibStubsPtr->xSetDashes) /* 0 */
diff --git a/generic/tkPlatDecls.h b/generic/tkPlatDecls.h
index 5b386ee..476fa4a 100644
--- a/generic/tkPlatDecls.h
+++ b/generic/tkPlatDecls.h
@@ -29,7 +29,7 @@
* Exported function declarations:
*/
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
#ifndef Tk_AttachHWND_TCL_DECLARED
#define Tk_AttachHWND_TCL_DECLARED
/* 0 */
@@ -131,7 +131,7 @@ typedef struct TkPlatStubs {
int magic;
struct TkPlatStubHooks *hooks;
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
Window (*tk_AttachHWND) (Tk_Window tkwin, HWND hwnd); /* 0 */
HINSTANCE (*tk_GetHINSTANCE) (void); /* 1 */
HWND (*tk_GetHWND) (Window window); /* 2 */
@@ -168,7 +168,7 @@ extern TkPlatStubs *tkPlatStubsPtr;
* Inline function declarations:
*/
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
#ifndef Tk_AttachHWND
#define Tk_AttachHWND \
(tkPlatStubsPtr->tk_AttachHWND) /* 0 */
diff --git a/generic/tkStubInit.c b/generic/tkStubInit.c
index 63250c5..03c794e 100644
--- a/generic/tkStubInit.c
+++ b/generic/tkStubInit.c
@@ -321,7 +321,7 @@ TkIntStubs tkIntStubs = {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 121 */
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
NULL, /* 121 */
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
@@ -331,7 +331,7 @@ TkIntStubs tkIntStubs = {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 122 */
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
NULL, /* 122 */
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
@@ -342,7 +342,7 @@ TkIntStubs tkIntStubs = {
#if !(defined(__WIN32__) || defined(MAC_OSX_TK)) /* X11 */
NULL, /* 124 */
#endif /* X11 */
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
NULL, /* 124 */
#endif /* WIN */
#ifdef MAC_OSX_TK /* AQUA */
@@ -538,7 +538,7 @@ TkIntPlatStubs tkIntPlatStubs = {
TkIntXlibStubs tkIntXlibStubs = {
TCL_STUB_MAGIC,
NULL,
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) /* WIN */
XSetDashes, /* 0 */
XGetModifierMapping, /* 1 */
XCreateImage, /* 2 */
@@ -746,7 +746,7 @@ TkIntXlibStubs tkIntXlibStubs = {
TkPlatStubs tkPlatStubs = {
TCL_STUB_MAGIC,
NULL,
-#ifdef __WIN32__ /* WIN */
+#if defined(__WIN32__) || defined(__CYGWIN__) /* WIN */
Tk_AttachHWND, /* 0 */
Tk_GetHINSTANCE, /* 1 */
Tk_GetHWND, /* 2 */
diff --git a/win/Makefile.in b/win/Makefile.in
index 5f9fd46..7958e3c 100644
--- a/win/Makefile.in
+++ b/win/Makefile.in
@@ -705,7 +705,7 @@ $(GENERIC_DIR)/tkStubInit.c: $(GENERIC_DIR)/tk.decls \
@echo "This warning can be safely ignored, do not report as a bug!"
genstubs:
- $(TCL_EXE) "$(TCL_TOOL_DIR)\genStubs.tcl" \
+ $(TCL_EXE) "$(TCL_TOOL_DIR)/genStubs.tcl" \
"$(GENERIC_DIR_NATIVE)" \
- "$(GENERIC_DIR_NATIVE)\tk.decls" \
- "$(GENERIC_DIR_NATIVE)\tkInt.decls"
+ "$(GENERIC_DIR_NATIVE)/tk.decls" \
+ "$(GENERIC_DIR_NATIVE)/tkInt.decls"
diff --git a/win/stubs.c b/win/stubs.c
index 1138ccb..00030d1 100644
--- a/win/stubs.c
+++ b/win/stubs.c
@@ -252,7 +252,7 @@ void
XSetCommand(
Display *display,
Window w,
- CONST char **argv,
+ char **argv,
int argc)
{
}
diff --git a/win/tkWinWm.c b/win/tkWinWm.c
index bb7f746..e3816ca 100644
--- a/win/tkWinWm.c
+++ b/win/tkWinWm.c
@@ -3567,7 +3567,7 @@ WmCommandCmd(
wmPtr->cmdArgc = cmdArgc;
wmPtr->cmdArgv = cmdArgv;
if (!(wmPtr->flags & WM_NEVER_MAPPED)) {
- XSetCommand(winPtr->display, winPtr->window, cmdArgv, cmdArgc);
+ XSetCommand(winPtr->display, winPtr->window, (char **) cmdArgv, cmdArgc);
}
return TCL_OK;
}