summaryrefslogtreecommitdiffstats
path: root/generic/tkCmds.c
diff options
context:
space:
mode:
authorjenglish <jenglish@flightlab.com>2013-02-27 14:41:41 (GMT)
committerjenglish <jenglish@flightlab.com>2013-02-27 14:41:41 (GMT)
commit2b76c49e30421aa22968c63e57c49bfaa6238e2f (patch)
treee4c799bd7715375437a5ca9333297d2092c73630 /generic/tkCmds.c
parentb83ed80002d8d8eb676c9f7c81a794e8216e3498 (diff)
downloadtk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.zip
tk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.tar.gz
tk-2b76c49e30421aa22968c63e57c49bfaa6238e2f.tar.bz2
Revert [ac229dabaa]. There is a reason the Tcl_GetIndexFromObj wrapper
exists and is used.
Diffstat (limited to 'generic/tkCmds.c')
-rw-r--r--generic/tkCmds.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/generic/tkCmds.c b/generic/tkCmds.c
index f7fa27c..4933d34 100644
--- a/generic/tkCmds.c
+++ b/generic/tkCmds.c
@@ -760,8 +760,8 @@ CaretCmd(
* Return the current value of the selected option
*/
- if (Tcl_GetIndexFromObjStruct(interp, objv[2], caretStrings,
- sizeof(char *), "caret option", 0, &index) != TCL_OK) {
+ if (Tcl_GetIndexFromObj(interp, objv[2], caretStrings,
+ "caret option", 0, &index) != TCL_OK) {
return TCL_ERROR;
}
if (index == TK_CARET_X) {
@@ -776,8 +776,8 @@ CaretCmd(
int i, value, x = 0, y = 0, height = -1;
for (i = 2; i < objc; i += 2) {
- if ((Tcl_GetIndexFromObjStruct(interp, objv[i], caretStrings,
- sizeof(char *), "caret option", 0, &index) != TCL_OK) ||
+ if ((Tcl_GetIndexFromObj(interp, objv[i], caretStrings,
+ "caret option", 0, &index) != TCL_OK) ||
Tcl_GetIntFromObj(interp,objv[i+1],&value) != TCL_OK) {
return TCL_ERROR;
}
@@ -1011,8 +1011,8 @@ Tk_TkwaitObjCmd(
return TCL_ERROR;
}
- if (Tcl_GetIndexFromObjStruct(interp, objv[1], optionStrings,
- sizeof(char *), "option", 0, &index) != TCL_OK) {
+ if (Tcl_GetIndexFromObj(interp, objv[1], optionStrings, "option", 0,
+ &index) != TCL_OK) {
return TCL_ERROR;
}
@@ -1192,8 +1192,8 @@ Tk_UpdateObjCmd(
if (objc == 1) {
flags = TCL_DONT_WAIT;
} else if (objc == 2) {
- if (Tcl_GetIndexFromObjStruct(interp, objv[1], updateOptions,
- sizeof(char *), "option", 0, &index) != TCL_OK) {
+ if (Tcl_GetIndexFromObj(interp, objv[1], updateOptions, "option", 0,
+ &index) != TCL_OK) {
return TCL_ERROR;
}
flags = TCL_IDLE_EVENTS;
@@ -1339,8 +1339,8 @@ Tk_WinfoObjCmd(
Tcl_WrongNumArgs(interp, 1, objv, "option ?arg?");
return TCL_ERROR;
}
- if (Tcl_GetIndexFromObjStruct(interp, objv[1], optionStrings,
- sizeof(char *), "option", 0, &index) != TCL_OK) {
+ if (Tcl_GetIndexFromObj(interp, objv[1], optionStrings, "option", 0,
+ &index) != TCL_OK) {
return TCL_ERROR;
}
@@ -1863,8 +1863,8 @@ Tk_WmObjCmd(
Tcl_WrongNumArgs(interp, 1, objv, "option window ?arg?");
return TCL_ERROR;
}
- if (Tcl_GetIndexFromObjStruct(interp, objv[1], optionStrings,
- sizeof(char *), "option", 0, &index) != TCL_OK) {
+ if (Tcl_GetIndexFromObj(interp, objv[1], optionStrings, "option", 0,
+ &index) != TCL_OK) {
return TCL_ERROR;
}