summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXImage.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2023-03-04 21:52:10 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2023-03-04 21:52:10 (GMT)
commitc565904256ce552372be8e3f3171082bb0cf51f7 (patch)
treec44d1cb87ddb9ee27228b47fac1d2dd48b947de2 /macosx/tkMacOSXImage.c
parent5a03048c707ee966457a12a6901c488012ecde2c (diff)
downloadtk-c565904256ce552372be8e3f3171082bb0cf51f7.zip
tk-c565904256ce552372be8e3f3171082bb0cf51f7.tar.gz
tk-c565904256ce552372be8e3f3171082bb0cf51f7.tar.bz2
More serious elimination of -Wconversion C warnings
Diffstat (limited to 'macosx/tkMacOSXImage.c')
-rw-r--r--macosx/tkMacOSXImage.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/macosx/tkMacOSXImage.c b/macosx/tkMacOSXImage.c
index 36e686c..9169530 100644
--- a/macosx/tkMacOSXImage.c
+++ b/macosx/tkMacOSXImage.c
@@ -1232,7 +1232,7 @@ TkMacOSXNSImageConfigureModel(
int oldWidth = modelPtr->width, oldHeight = modelPtr->height;
if (asOption == NULL) {
- asOption = Tcl_NewStringObj("-as", -1);
+ asOption = Tcl_NewStringObj("-as", TCL_INDEX_NONE);
Tcl_IncrRefCount(asOption);
}
@@ -1248,7 +1248,7 @@ TkMacOSXNSImageConfigureModel(
}
if (modelPtr->source == NULL || modelPtr->source[0] == '0') {
- Tcl_SetObjResult(interp, Tcl_NewStringObj("-source is required.", -1));
+ Tcl_SetObjResult(interp, Tcl_NewStringObj("-source is required.", TCL_INDEX_NONE));
Tcl_SetErrorCode(interp, "TK", "IMAGE", "SYSTEM", "BAD_VALUE", NULL);
goto errorExit;
}
@@ -1259,7 +1259,7 @@ TkMacOSXNSImageConfigureModel(
0, &sourceInterpretation) != TCL_OK) {
Tcl_SetObjResult(interp, Tcl_NewStringObj(
"Unknown interpretation for source in -as option. "
- "Should be name, file, path, or filetype.", -1));
+ "Should be name, file, path, or filetype.", TCL_INDEX_NONE));
Tcl_SetErrorCode(interp, "TK", "IMAGE", "SYSTEM", "BAD_VALUE", NULL);
goto errorExit;
}
@@ -1320,18 +1320,18 @@ TkMacOSXNSImageConfigureModel(
case NAME_SOURCE:
Tcl_SetObjResult(interp, Tcl_NewStringObj("Unknown named NSImage.\n"
"Try omitting ImageName, "
- "e.g. use NSCaution for NSImageNameCaution.", -1));
+ "e.g. use NSCaution for NSImageNameCaution.", TCL_INDEX_NONE));
Tcl_SetErrorCode(interp, "TK", "IMAGE", "SYSTEM", "BAD_VALUE", NULL);
goto errorExit;
case FILE_SOURCE:
Tcl_SetObjResult(interp, Tcl_NewStringObj(
- "Failed to load image file.\n", -1));
+ "Failed to load image file.\n", TCL_INDEX_NONE));
Tcl_SetErrorCode(interp, "TK", "IMAGE", "SYSTEM", "BAD_VALUE", NULL);
goto errorExit;
default:
Tcl_SetObjResult(interp, Tcl_NewStringObj(
"Unrecognized file type.\n"
- "If using a filename extension, do not include the dot.\n", -1));
+ "If using a filename extension, do not include the dot.\n", TCL_INDEX_NONE));
Tcl_SetErrorCode(interp, "TK", "IMAGE", "SYSTEM", "BAD_VALUE", NULL);
goto errorExit;
}