diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-02-27 12:36:56 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-02-27 12:36:56 (GMT) |
commit | b83ed80002d8d8eb676c9f7c81a794e8216e3498 (patch) | |
tree | c60953cf292d7784e416ed6fd0555d89d2e6f2c3 /generic/tkListbox.c | |
parent | fb81bb7d6255f5040661d59559edf32bc997bd6d (diff) | |
download | tk-b83ed80002d8d8eb676c9f7c81a794e8216e3498.zip tk-b83ed80002d8d8eb676c9f7c81a794e8216e3498.tar.gz tk-b83ed80002d8d8eb676c9f7c81a794e8216e3498.tar.bz2 |
Eliminate all Tcl_GetIndexFromObj calls, which is only a thin wrapper around Tcl_GetIndexFromObjStruct.
Diffstat (limited to 'generic/tkListbox.c')
-rw-r--r-- | generic/tkListbox.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/generic/tkListbox.c b/generic/tkListbox.c index c5460f9..77a2d34 100644 --- a/generic/tkListbox.c +++ b/generic/tkListbox.c @@ -615,8 +615,8 @@ ListboxWidgetObjCmd( * valid subcommand names */ - result = Tcl_GetIndexFromObj(interp, objv[1], commandNames, - "option", 0, &cmdIndex); + result = Tcl_GetIndexFromObjStruct(interp, objv[1], commandNames, + sizeof(char *), "option", 0, &cmdIndex); if (result != TCL_OK) { return result; } @@ -969,8 +969,8 @@ ListboxWidgetObjCmd( break; } - result = Tcl_GetIndexFromObj(interp, objv[2], scanCommandNames, - "option", 0, &scanCmdIndex); + result = Tcl_GetIndexFromObjStruct(interp, objv[2], scanCommandNames, + sizeof(char *), "option", 0, &scanCmdIndex); if (result != TCL_OK) { break; } @@ -1164,8 +1164,8 @@ ListboxSelectionSubCmd( return result; } } - result = Tcl_GetIndexFromObj(interp, objv[2], selCommandNames, - "option", 0, &selCmdIndex); + result = Tcl_GetIndexFromObjStruct(interp, objv[2], selCommandNames, + sizeof(char *), "option", 0, &selCmdIndex); if (result != TCL_OK) { return result; } @@ -2709,7 +2709,8 @@ GetListboxIndex( * First see if the index is one of the named indices. */ - result = Tcl_GetIndexFromObj(NULL, indexObj, indexNames, "", 0, &index); + result = Tcl_GetIndexFromObjStruct(NULL, indexObj, indexNames, + sizeof(char *), "", 0, &index); if (result == TCL_OK) { switch (index) { case INDEX_ACTIVE: |