summaryrefslogtreecommitdiffstats
path: root/win/tkWinTest.c
diff options
context:
space:
mode:
Diffstat (limited to 'win/tkWinTest.c')
-rw-r--r--win/tkWinTest.c23
1 files changed, 15 insertions, 8 deletions
diff --git a/win/tkWinTest.c b/win/tkWinTest.c
index 613eda3..c419be8 100644
--- a/win/tkWinTest.c
+++ b/win/tkWinTest.c
@@ -231,6 +231,8 @@ SetSelectionResult(
Tcl_Interp *interp,
const char *selection)
{
+ (void)dummy;
+
Tcl_AppendResult(interp, selection, NULL);
return TCL_OK;
}
@@ -242,7 +244,7 @@ TestclipboardObjCmd(
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument values. */
{
- Tk_Window tkwin = clientData;
+ Tk_Window tkwin = (Tk_Window)clientData;
if (objc != 1) {
Tcl_WrongNumArgs(interp, 1, objv, NULL);
@@ -271,7 +273,7 @@ TestclipboardObjCmd(
static int
TestwineventObjCmd(
- ClientData clientData, /* Main window for application. */
+ ClientData dummy, /* Main window for application. */
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument strings. */
@@ -304,6 +306,7 @@ TestwineventObjCmd(
{WM_COMMAND, "WM_COMMAND"},
{-1, NULL}
};
+ (void)dummy;
if ((objc == 3) && (strcmp(Tcl_GetString(objv[1]), "debug") == 0)) {
int b;
@@ -319,7 +322,7 @@ TestwineventObjCmd(
return TCL_ERROR;
}
- hwnd = INT2PTR(strtol(Tcl_GetString(objv[1]), &rest, 0));
+ hwnd = (HWND)INT2PTR(strtol(Tcl_GetString(objv[1]), &rest, 0));
if (rest == Tcl_GetString(objv[1])) {
hwnd = FindWindowA(NULL, Tcl_GetString(objv[1]));
if (hwnd == NULL) {
@@ -439,7 +442,7 @@ TestwineventObjCmd(
static int
TestfindwindowObjCmd(
- ClientData clientData, /* Main window for application. */
+ ClientData dummy, /* Main window for application. */
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument values. */
@@ -449,6 +452,7 @@ TestfindwindowObjCmd(
HWND hwnd = NULL;
int r = TCL_OK;
DWORD myPid;
+ (void)dummy;
Tcl_DStringInit(&classString);
Tcl_DStringInit(&titleString);
@@ -511,7 +515,7 @@ EnumChildrenProc(
static int
TestgetwindowinfoObjCmd(
- ClientData clientData,
+ ClientData dummy,
Tcl_Interp *interp,
int objc,
Tcl_Obj *const objv[])
@@ -522,6 +526,7 @@ TestgetwindowinfoObjCmd(
WCHAR buf[512];
int cch, cchBuf = 256;
Tcl_DString ds;
+ (void)dummy;
if (objc != 2) {
Tcl_WrongNumArgs(interp, 1, objv, "hwnd");
@@ -531,7 +536,7 @@ TestgetwindowinfoObjCmd(
if (Tcl_GetWideIntFromObj(interp, objv[1], &hwnd) != TCL_OK)
return TCL_ERROR;
- cch = GetClassNameW(INT2PTR(hwnd), buf, cchBuf);
+ cch = GetClassNameW((HWND)INT2PTR(hwnd), buf, cchBuf);
if (cch == 0) {
Tcl_SetObjResult(interp, Tcl_NewStringObj("failed to get class name: ", -1));
AppendSystemError(interp, GetLastError());
@@ -548,7 +553,7 @@ TestgetwindowinfoObjCmd(
Tcl_DictObjPut(interp, dictObj, Tcl_NewStringObj("id", 2),
Tcl_NewWideIntObj(GetWindowLongPtr((HWND)(size_t)hwnd, GWL_ID)));
- cch = GetWindowTextW(INT2PTR(hwnd), buf, cchBuf);
+ cch = GetWindowTextW((HWND)INT2PTR(hwnd), buf, cchBuf);
Tcl_DStringInit(&ds);
Tcl_WCharToUtfDString(buf, cch, &ds);
textObj = Tcl_NewStringObj(Tcl_DStringValue(&ds), Tcl_DStringLength(&ds));
@@ -568,11 +573,13 @@ TestgetwindowinfoObjCmd(
static int
TestwinlocaleObjCmd(
- ClientData clientData, /* Main window for application. */
+ ClientData dummy, /* Main window for application. */
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
Tcl_Obj *const objv[]) /* Argument values. */
{
+ (void)dummy;
+
if (objc != 1) {
Tcl_WrongNumArgs(interp, 1, objv, NULL);
return TCL_ERROR;