diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2021-01-13 16:09:02 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2021-01-13 16:09:02 (GMT) |
commit | 272246c6734a790336960502387c067c8bbec581 (patch) | |
tree | 23f3392770e3cb5aeffe3114c7679fdeedaed585 /win | |
parent | 15546b6cebdff29f3292695692e924c962158bba (diff) | |
parent | 077491facaf37abdab56ceb12848abecded4a190 (diff) | |
download | tk-272246c6734a790336960502387c067c8bbec581.zip tk-272246c6734a790336960502387c067c8bbec581.tar.gz tk-272246c6734a790336960502387c067c8bbec581.tar.bz2 |
Eliminate internal TkGetByteArrayFromObj() and TkGetStringFromObj() functions: Thanks to TIP #481 those are no longer needed.
Diffstat (limited to 'win')
-rw-r--r-- | win/tkWinDialog.c | 2 | ||||
-rw-r--r-- | win/tkWinMenu.c | 2 | ||||
-rw-r--r-- | win/tkWinWm.c | 16 | ||||
-rw-r--r-- | win/ttkWinXPTheme.c | 6 |
4 files changed, 13 insertions, 13 deletions
diff --git a/win/tkWinDialog.c b/win/tkWinDialog.c index 7ff69a3..d2267d8 100644 --- a/win/tkWinDialog.c +++ b/win/tkWinDialog.c @@ -2061,7 +2061,7 @@ MakeFilter( if (valuePtr == NULL) { len = 0; } else { - (void) TkGetStringFromObj(valuePtr, &len); + (void) Tcl_GetStringFromObj(valuePtr, &len); } /* diff --git a/win/tkWinMenu.c b/win/tkWinMenu.c index d6ce571..02daf16 100644 --- a/win/tkWinMenu.c +++ b/win/tkWinMenu.c @@ -1275,7 +1275,7 @@ TkWinHandleMenuEvent( /* * Ensure we don't exceed the label length, then check */ - const char *src = TkGetStringFromObj(labelPtr, &len); + const char *src = Tcl_GetStringFromObj(labelPtr, &len); Tcl_DStringFree(&ds); Tcl_DStringInit(&ds); diff --git a/win/tkWinWm.c b/win/tkWinWm.c index a395a65..153a7a3 100644 --- a/win/tkWinWm.c +++ b/win/tkWinWm.c @@ -2646,7 +2646,7 @@ Tk_WmObjCmd( return TCL_ERROR; } - argv1 = TkGetStringFromObj(objv[1], &length); + argv1 = Tcl_GetStringFromObj(objv[1], &length); if ((argv1[0] == 't') && !strncmp(argv1, "tracing", length) && (length >= 3)) { int wmTracing; @@ -2911,7 +2911,7 @@ WmAttributesCmd( return TCL_OK; } for (i = 3; i < objc; i += 2) { - string = TkGetStringFromObj(objv[i], &length); + string = Tcl_GetStringFromObj(objv[i], &length); if ((length < 2) || (string[0] != '-')) { goto configArgs; } @@ -2979,7 +2979,7 @@ WmAttributesCmd( } wmPtr->alpha = dval; } else { /* -transparentcolor */ - const char *crefstr = TkGetStringFromObj(objv[i+1], &length); + const char *crefstr = Tcl_GetStringFromObj(objv[i+1], &length); if (length == 0) { /* reset to no transparent color */ @@ -3172,7 +3172,7 @@ WmClientCmd( } return TCL_OK; } - argv3 = TkGetStringFromObj(objv[3], &length); + argv3 = Tcl_GetStringFromObj(objv[3], &length); if (argv3[0] == 0) { if (wmPtr->clientMachine != NULL) { ckfree(wmPtr->clientMachine); @@ -3782,7 +3782,7 @@ WmGroupCmd( } return TCL_OK; } - argv3 = TkGetStringFromObj(objv[3], &length); + argv3 = Tcl_GetStringFromObj(objv[3], &length); if (*argv3 == '\0') { wmPtr->hints.flags &= ~WindowGroupHint; if (wmPtr->leaderName != NULL) { @@ -4109,7 +4109,7 @@ WmIconnameCmd( if (wmPtr->iconName != NULL) { ckfree(wmPtr->iconName); } - argv3 = TkGetStringFromObj(objv[3], &length); + argv3 = Tcl_GetStringFromObj(objv[3], &length); wmPtr->iconName = (char *)ckalloc(length + 1); memcpy(wmPtr->iconName, argv3, length + 1); if (!(wmPtr->flags & WM_NEVER_MAPPED)) { @@ -4786,7 +4786,7 @@ WmProtocolCmd( break; } } - cmd = TkGetStringFromObj(objv[4], &cmdLength); + cmd = Tcl_GetStringFromObj(objv[4], &cmdLength); if (cmdLength > 0) { protPtr = (ProtocolHandler *)ckalloc(HANDLER_SIZE(cmdLength)); protPtr->protocol = protocol; @@ -5262,7 +5262,7 @@ WmTitleCmd( if (wmPtr->title != NULL) { ckfree(wmPtr->title); } - argv3 = TkGetStringFromObj(objv[3], &length); + argv3 = Tcl_GetStringFromObj(objv[3], &length); wmPtr->title = (char *)ckalloc(length + 1); memcpy(wmPtr->title, argv3, length + 1); diff --git a/win/ttkWinXPTheme.c b/win/ttkWinXPTheme.c index 1d61186..3fedff7 100644 --- a/win/ttkWinXPTheme.c +++ b/win/ttkWinXPTheme.c @@ -838,7 +838,7 @@ static void TextElementSize( if (!InitElementData(elementData, tkwin, 0)) return; - src = TkGetStringFromObj(element->textObj, &len); + src = Tcl_GetStringFromObj(element->textObj, &len); Tcl_DStringInit(&ds); hr = elementData->procs->GetThemeTextExtent( elementData->hTheme, @@ -877,7 +877,7 @@ static void TextElementDraw( if (!InitElementData(elementData, tkwin, d)) return; - src = TkGetStringFromObj(element->textObj, &len); + src = Tcl_GetStringFromObj(element->textObj, &len); Tcl_DStringInit(&ds); hr = elementData->procs->DrawThemeText( elementData->hTheme, @@ -1142,7 +1142,7 @@ Ttk_CreateVsapiElement( if (Tcl_GetIntFromObj(interp, objv[1], &partId) != TCL_OK) { return TCL_ERROR; } - name = TkGetStringFromObj(objv[0], &length); + name = Tcl_GetStringFromObj(objv[0], &length); Tcl_DStringInit(&classBuf); className = Tcl_UtfToWCharDString(name, length, &classBuf); |