mirror of
https://github.com/Ponce/slackbuilds
synced 2024-11-29 13:00:32 +01:00
377171575b
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
899 lines
25 KiB
Diff
899 lines
25 KiB
Diff
Description: Patch deletes or comments out all unused variables.
|
|
Author: Sergei Golovan
|
|
Last-Modified: Wed, 09 Jul 2014 19:18:23 +0400
|
|
|
|
--- a/generic/bltTree.c
|
|
+++ b/generic/bltTree.c
|
|
@@ -1234,7 +1234,7 @@
|
|
int
|
|
Blt_TreeRelabelNode(TreeClient *clientPtr, Node *nodePtr, CONST char *string)
|
|
{
|
|
- int result, inode;
|
|
+ int result;
|
|
if ((result=NotifyClients(clientPtr, clientPtr->treeObject, nodePtr,
|
|
TREE_NOTIFY_RELABEL)) != TCL_OK) {
|
|
return result;
|
|
@@ -1245,7 +1245,6 @@
|
|
* been created.
|
|
*/
|
|
SetModified(nodePtr);
|
|
- inode = nodePtr->inode;
|
|
result = NotifyClients(clientPtr, clientPtr->treeObject, nodePtr,
|
|
TREE_NOTIFY_RELABELPOST);
|
|
return result;
|
|
--- a/generic/bltTreeCmd.c
|
|
+++ b/generic/bltTreeCmd.c
|
|
@@ -2078,10 +2078,8 @@
|
|
SetValues(TreeCmd *cmdPtr, Blt_TreeNode node, int objc, Tcl_Obj *CONST *objv)
|
|
{
|
|
register int i;
|
|
- int inode;
|
|
char *string;
|
|
|
|
- inode = node->inode;
|
|
for (i = 0; i < objc; i += 2) {
|
|
string = Tcl_GetString(objv[i]);
|
|
if ((i + 1) == objc) {
|
|
@@ -2108,11 +2106,10 @@
|
|
{
|
|
register int i;
|
|
char *string;
|
|
- int result = TCL_OK, inode;
|
|
+ int result = TCL_OK;
|
|
Tcl_DString dStr;
|
|
Tcl_Interp *interp = cmdPtr->interp;
|
|
|
|
- inode = node->inode;
|
|
if (objc % 2) {
|
|
Tcl_AppendResult(interp, "odd # values", (char *)NULL);
|
|
return TCL_ERROR;
|
|
@@ -4552,7 +4549,7 @@
|
|
Blt_TreeNode parent = NULL, child = NULL;
|
|
int cnt = 0, i, n, m, vobjc, tobjc, dobjc, pobjc, optInd, iPos = -1, incr = 0;
|
|
int hasoffs = 0, seqlabel = 0, seqVal = 0, hasstart = 0, start;
|
|
- int fixed = 0, hasnum = 0, hcnt = 0;
|
|
+ int fixed = 0, hcnt = 0;
|
|
char *prefix = NULL, *string;
|
|
Tcl_Obj **vobjv = NULL;
|
|
Tcl_Obj **tobjv = NULL;
|
|
@@ -4628,7 +4625,6 @@
|
|
if (Tcl_GetIntFromObj(interp, objv[3], &cnt) != TCL_OK) {
|
|
return TCL_ERROR;
|
|
}
|
|
- hasnum = 1;
|
|
hcnt++;
|
|
if (cnt<0 || cnt>10000000) {
|
|
Tcl_AppendResult(interp, "count must be >= 0 and <= 10M", (char *)NULL);
|
|
@@ -4982,13 +4978,13 @@
|
|
Tcl_Obj *listObjPtr, *objPtr;
|
|
register int i;
|
|
int isNew, len;
|
|
- char *string;
|
|
+ /*char *string;*/
|
|
TagSearch tagIter = {0};
|
|
|
|
Blt_InitHashTableWithPool(&keyTable, BLT_ONE_WORD_KEYS);
|
|
listObjPtr = Tcl_NewListObj(0, (Tcl_Obj **) NULL);
|
|
for (i = 2; i < objc; i++) {
|
|
- string = Tcl_GetStringFromObj(objv[i],&len);
|
|
+ /*string =*/ Tcl_GetStringFromObj(objv[i],&len);
|
|
if (len == 0) continue;
|
|
if (FindTaggedNodes(interp, cmdPtr, objv[i], &tagIter) != TCL_OK) {
|
|
Blt_DeleteHashTable(&keyTable);
|
|
@@ -6525,7 +6521,7 @@
|
|
Blt_TreeNode node;
|
|
char *string;
|
|
Tcl_Obj *valuePtr;
|
|
- int i, result = TCL_OK, inode;
|
|
+ int i, result = TCL_OK;
|
|
Tcl_DString dStr;
|
|
|
|
if (GetNode(cmdPtr, objv[2], &node) != TCL_OK) {
|
|
@@ -6540,7 +6536,6 @@
|
|
cmdPtr->updTyp = 0;
|
|
}
|
|
Tcl_DStringInit(&dStr);
|
|
- inode = node->inode;
|
|
for (i=3; i<objc; i+=2) {
|
|
string = Tcl_GetString(objv[i]);
|
|
if (Blt_TreeGetValue(interp, cmdPtr->tree, node, string,
|
|
@@ -6599,11 +6594,11 @@
|
|
Tcl_Obj *CONST *objv)
|
|
{
|
|
Blt_TreeNode node;
|
|
- char *string;
|
|
+ /*char *string;*/
|
|
int count = 0, len;
|
|
TagSearch cursor = {0};
|
|
|
|
- string = Tcl_GetStringFromObj(objv[2],&len);
|
|
+ /*string =*/ Tcl_GetStringFromObj(objv[2],&len);
|
|
if (len == 0) {
|
|
Tcl_SetObjResult(interp, Tcl_NewIntObj(0));
|
|
return TCL_OK;
|
|
@@ -6834,7 +6829,7 @@
|
|
Tcl_Obj *CONST *objv)
|
|
{
|
|
Blt_TreeNode node;
|
|
- char *string;
|
|
+ /*char *string;*/
|
|
int count = 0, result = TCL_OK, len;
|
|
Tcl_DString dStr;
|
|
TagSearch cursor = {0};
|
|
@@ -6844,7 +6839,7 @@
|
|
return TCL_ERROR;
|
|
}
|
|
if (objc<=3) return TCL_OK;
|
|
- string = Tcl_GetStringFromObj(objv[2], &len);
|
|
+ /*string =*/ Tcl_GetStringFromObj(objv[2], &len);
|
|
if (len == 0) {
|
|
Tcl_SetObjResult(interp, Tcl_NewIntObj(0));
|
|
return TCL_OK;
|
|
@@ -7169,7 +7164,6 @@
|
|
Blt_TreeNode node;
|
|
Tcl_Obj *listObjPtr;
|
|
Tcl_Obj *objPtr;
|
|
- char *string;
|
|
int isNew;
|
|
register int i;
|
|
|
|
@@ -7177,7 +7171,6 @@
|
|
for (i = 3; i < objc; i++) {
|
|
TagSearch tcursor = {0};
|
|
|
|
- string = Tcl_GetString(objv[i]);
|
|
if (FindTaggedNodes(interp, cmdPtr, objv[i], &tcursor) != TCL_OK) {
|
|
Tcl_ResetResult(interp);
|
|
DoneTaggedNodes(&tcursor);
|
|
@@ -7756,12 +7749,9 @@
|
|
Tcl_Obj *CONST *objv)
|
|
{
|
|
Blt_TreeNode node;
|
|
- char *string;
|
|
int count = 0;
|
|
TagSearch cursor = {0};
|
|
|
|
- string = Tcl_GetString(objv[2]);
|
|
-
|
|
if (FindTaggedNodes(interp, cmdPtr, objv[2], &cursor) != TCL_OK) {
|
|
return TCL_ERROR;
|
|
}
|
|
@@ -8084,7 +8074,7 @@
|
|
Tcl_Obj *valuePtr, *varObj, *nullObj = NULL, *nodeObj = NULL;
|
|
Tcl_Obj *hashObj = NULL, *starObj = NULL;
|
|
Blt_TreeKeySearch keyIter;
|
|
- int vobjc, kobjc, i, result = TCL_OK, len, cnt = 0, isar;
|
|
+ int vobjc, kobjc, i, result = TCL_OK, len, cnt = 0/*, isar */;
|
|
int nobreak = 0, noupdate = 0, unset = 0, init = 0, aLen;
|
|
char *var, *string, *aName = NULL, *aPat = NULL;
|
|
int klen, kl, j;
|
|
@@ -8251,7 +8241,7 @@
|
|
}
|
|
}
|
|
|
|
- isar = 0;
|
|
+ /* isar = 0; */
|
|
if (arrName != NULL) {
|
|
kl = strlen(aName);
|
|
|
|
@@ -8526,7 +8516,7 @@
|
|
{
|
|
Blt_TreeNode node;
|
|
int len, result;
|
|
- char *var, *string;
|
|
+ char *var/*, *string*/;
|
|
TagSearch cursor = {0};
|
|
|
|
var = Tcl_GetString(objv[2]);
|
|
@@ -8535,7 +8525,7 @@
|
|
Tcl_AppendResult(interp, "wrong number of args ", 0);
|
|
return TCL_ERROR;
|
|
}
|
|
- string = Tcl_GetStringFromObj(objv[3],&len);
|
|
+ /*string =*/ Tcl_GetStringFromObj(objv[3],&len);
|
|
if (len == 0) {
|
|
Tcl_SetObjResult(interp, Tcl_NewIntObj(0));
|
|
return TCL_OK;
|
|
@@ -8894,6 +8884,7 @@
|
|
* Obj Callback for sqlload.
|
|
*
|
|
*/
|
|
+#if 0
|
|
static int SqlCallbackObj(SqlData *sqlPtr, int argc, Tcl_Obj **objv, Tcl_Obj **azColName)
|
|
{
|
|
int i, j, rid, lid, n, tcid, vobjc, tobjc;
|
|
@@ -9122,6 +9113,7 @@
|
|
return 1;
|
|
}
|
|
#endif
|
|
+#endif
|
|
|
|
#ifndef OMIT_SQLITE3_LOAD
|
|
/* #include <sqlite3.h> */
|
|
--- a/generic/bltInit.c
|
|
+++ b/generic/bltInit.c
|
|
@@ -438,9 +438,9 @@
|
|
{
|
|
Tcl_DString dString;
|
|
CONST char *value;
|
|
+#ifndef TCL_ONLY
|
|
static int tkisinit = 0;
|
|
|
|
-#ifndef TCL_ONLY
|
|
if (!tkisinit) {
|
|
struct TileHandlers *thPtr;
|
|
|
|
@@ -510,7 +510,9 @@
|
|
Tcl_Interp *interp; /* Interpreter to add extra commands */
|
|
{
|
|
int flags;
|
|
+#ifdef USE_BLT_STUBS
|
|
int dostub = 0;
|
|
+#endif
|
|
|
|
flags = (int)Tcl_GetAssocData(interp, BLT_THREAD_KEY, NULL);
|
|
if ((flags & BLT_TCL_CMDS) == 0) {
|
|
--- a/generic/bltColor.c
|
|
+++ b/generic/bltColor.c
|
|
@@ -77,7 +77,7 @@
|
|
|
|
#define NCOLORS 256
|
|
|
|
-
|
|
+#if 0
|
|
static void
|
|
GetPaletteSizes(nColors, nRedsPtr, nGreensPtr, nBluesPtr)
|
|
int nColors; /* Number of colors requested. */
|
|
@@ -129,6 +129,7 @@
|
|
}
|
|
|
|
}
|
|
+#endif
|
|
|
|
/*
|
|
*----------------------------------------------------------------------
|
|
@@ -200,6 +201,7 @@
|
|
return numAvail;
|
|
}
|
|
|
|
+#if 0
|
|
static void
|
|
FindClosestColor(colorPtr, mapColors, numMapColors)
|
|
ColorInfo *colorPtr;
|
|
@@ -342,6 +344,7 @@
|
|
colorTabPtr->nPixels = nImageColors;
|
|
return 1;
|
|
}
|
|
+#endif
|
|
|
|
ColorTable
|
|
Blt_CreateColorTable(tkwin)
|
|
@@ -510,6 +513,7 @@
|
|
return colorTabPtr;
|
|
}
|
|
|
|
+#if 0
|
|
/*
|
|
* First attempt:
|
|
* Allocate colors all the colors in the image (up to NCOLORS). Bail out
|
|
@@ -548,6 +552,7 @@
|
|
Blt_DeleteHashTable(&colorTable);
|
|
return nColors;
|
|
}
|
|
+#endif
|
|
|
|
#define Blt_DefaultColormap(tkwin) \
|
|
DefaultColormap(Tk_Display(tkwin), Tk_ScreenNumber(tkwin))
|
|
@@ -563,11 +568,11 @@
|
|
int keepColors = 0;
|
|
register int i;
|
|
XColor usedColors[NCOLORS];
|
|
- int nFreeColors, nUsedColors;
|
|
+ int nUsedColors;
|
|
Colormap colorMap;
|
|
int inUse[NCOLORS];
|
|
XColor *colorPtr;
|
|
- XColor *imageColors;
|
|
+ /* XColor *imageColors; */
|
|
|
|
/*
|
|
* Create a private colormap if one doesn't already exist for the
|
|
@@ -582,7 +587,7 @@
|
|
XFreeColors(colorTabPtr->display, colorTabPtr->colorMap,
|
|
colorTabPtr->pixelValues, colorTabPtr->nPixels, 0);
|
|
}
|
|
- nFreeColors = QueryColormap(colorTabPtr->display, colorMap, usedColors,
|
|
+ QueryColormap(colorTabPtr->display, colorMap, usedColors,
|
|
&nUsedColors);
|
|
memset((char *)inUse, 0, sizeof(int) * NCOLORS);
|
|
if ((nUsedColors == 0) && (keepColors > 0)) {
|
|
@@ -592,7 +597,7 @@
|
|
* have been used in the default colormap.
|
|
*/
|
|
|
|
- nFreeColors = QueryColormap(colorTabPtr->display,
|
|
+ QueryColormap(colorTabPtr->display,
|
|
Blt_DefaultColormap(tkwin), usedColors, &nUsedColors);
|
|
|
|
/*
|
|
@@ -622,7 +627,7 @@
|
|
* image as we can fit. If necessary, we'll cheat and reduce the number
|
|
* of colors by quantizing.
|
|
*/
|
|
- imageColors = usedColors + nUsedColors;
|
|
+ /* imageColors = usedColors + nUsedColors; */
|
|
|
|
Tk_SetWindowColormap(tkwin, colorMap);
|
|
}
|
|
--- a/generic/bltTabset.c
|
|
+++ b/generic/bltTabset.c
|
|
@@ -3916,12 +3916,9 @@
|
|
{
|
|
int x, y; /* Screen coordinates of the test point. */
|
|
Tab *tabPtr;
|
|
- int dw, dh;
|
|
char coords[200];
|
|
|
|
coords[0] = 0;
|
|
- dw = Tk_Width(setPtr->tkwin);
|
|
- dh = Tk_Height(setPtr->tkwin);
|
|
tabPtr = NULL;
|
|
if ((Tk_GetPixels(interp, setPtr->tkwin, argv[2], &x) != TCL_OK) ||
|
|
(Tk_GetPixels(interp, setPtr->tkwin, argv[3], &y) != TCL_OK)) {
|
|
@@ -5247,18 +5244,14 @@
|
|
Tab *startPtr, *nextPtr;
|
|
Blt_ChainLink *linkPtr;
|
|
register Tab *tabPtr;
|
|
- int x, maxWidth, sImg, eImg;
|
|
+ int x, maxWidth, sImg;
|
|
int vert = (setPtr->side & SIDE_VERTICAL);
|
|
|
|
sImg = 0;
|
|
- eImg = 0;
|
|
|
|
if (setPtr->startImage) {
|
|
sImg = (vert?setPtr->startImage->height:setPtr->startImage->width);
|
|
}
|
|
- if (setPtr->endImage) {
|
|
- eImg = (vert?setPtr->endImage->height:setPtr->endImage->width);
|
|
- }
|
|
|
|
tabsPerTier = (nTabs + (setPtr->nTiers - 1)) / setPtr->nTiers;
|
|
x = sImg;
|
|
--- a/generic/bltTile.c
|
|
+++ b/generic/bltTile.c
|
|
@@ -1176,10 +1176,7 @@
|
|
}
|
|
if (clientPtr->tilePtr->mask != None) {
|
|
Pixmap mask;
|
|
- int xm, ym;
|
|
|
|
- xm = clientPtr->xOrigin;
|
|
- ym = clientPtr->yOrigin;
|
|
mask = RectangleMask(display, drawable, x, y, width, height,
|
|
tilePtr->mask, clientPtr->xOrigin, clientPtr->yOrigin);
|
|
XSetClipMask(display, tilePtr->gc, mask);
|
|
--- a/generic/bltTreeView.c
|
|
+++ b/generic/bltTreeView.c
|
|
@@ -5042,7 +5042,7 @@
|
|
&& strlen(Tcl_GetString(tvPtr->imageCmd))) {
|
|
Tcl_DString cmdString;
|
|
char *string;
|
|
- int result, rcnt;
|
|
+ int /*result,*/ rcnt;
|
|
Tcl_Interp *interp = tvPtr->interp;
|
|
|
|
string = Blt_GetHashKey(&tvPtr->iconTable, icon->hashPtr);
|
|
@@ -5052,7 +5052,7 @@
|
|
if (entryPtr) Tcl_Preserve(entryPtr);
|
|
if (columnPtr) Tcl_Preserve(columnPtr);
|
|
Blt_TreeViewPercentSubst(tvPtr, entryPtr, columnPtr, Tcl_GetString(tvPtr->imageCmd), string, &cmdString);
|
|
- result = Tcl_GlobalEval(interp, Tcl_DStringValue(&cmdString));
|
|
+ /* result = */ Tcl_GlobalEval(interp, Tcl_DStringValue(&cmdString));
|
|
rcnt = icon->refCount;
|
|
Blt_TreeViewFreeIcon(tvPtr, icon);
|
|
if ((tvPtr->flags & TV_DELETED)
|
|
@@ -5286,10 +5286,10 @@
|
|
TreeViewIcon *icons;
|
|
TreeViewIcon icon;
|
|
|
|
- int isActive, hasFocus;
|
|
+ int isActive/*, hasFocus*/;
|
|
|
|
isActive = (entryPtr == tvPtr->activePtr);
|
|
- hasFocus = (entryPtr == tvPtr->focusPtr);
|
|
+ /*hasFocus = (entryPtr == tvPtr->focusPtr);*/
|
|
icons = NULL;
|
|
if (tvPtr->flags & TV_HIDE_ICONS) {
|
|
return NULL;
|
|
@@ -5879,9 +5879,9 @@
|
|
int x0, cx, xOffset;
|
|
TreeViewStyle *sPtr;
|
|
TreeViewIcon icon;
|
|
- int mw, mh;
|
|
+ int mw/*, mh*/;
|
|
mw = Tk_Width(tvPtr->tkwin) - tvPtr->padX;
|
|
- mh = Tk_Height(tvPtr->tkwin) - tvPtr->padY;
|
|
+ /* mh = Tk_Height(tvPtr->tkwin) - tvPtr->padY; */
|
|
|
|
if (tvPtr->titleHeight < 1) {
|
|
return;
|
|
--- a/generic/bltTreeViewCmd.c
|
|
+++ b/generic/bltTreeViewCmd.c
|
|
@@ -668,10 +668,8 @@
|
|
hPtr = Blt_FirstHashEntry(tablePtr, &infoPtr->cursor);
|
|
if (hPtr != NULL) {
|
|
Blt_TreeNode node;
|
|
- int inode;
|
|
|
|
node = Blt_GetHashValue(hPtr);
|
|
- inode = node->inode;
|
|
infoPtr->entryPtr = Blt_NodeToEntry(tvPtr, node);
|
|
if (infoPtr->entryPtr == NULL && cnt++ == 0) {
|
|
/* fprintf(stderr, "Dangling node: %d\n", node->inode); */
|
|
@@ -1689,13 +1687,11 @@
|
|
TreeViewEntry *entryPtr;
|
|
TreeViewColumn *columnPtr;
|
|
int n, result;
|
|
- Blt_TreeNode node;
|
|
char *left, *string;
|
|
|
|
if (GetEntryFromObj(tvPtr, objv[3], &entryPtr) != TCL_OK) {
|
|
return TCL_ERROR;
|
|
}
|
|
- node = entryPtr->node;
|
|
string = Tcl_GetString(objv[4]);
|
|
if (Blt_TreeViewGetColumnKey(interp, tvPtr, objv[4], &columnPtr, &left)
|
|
!= TCL_OK || columnPtr == NULL) {
|
|
@@ -1777,7 +1773,6 @@
|
|
{
|
|
TreeViewEntry *entryPtr;
|
|
TreeViewColumn *columnPtr;
|
|
- Blt_TreeNode node;
|
|
double dVal, dIncr = 1.0;
|
|
int iVal, iIncr = 1, isInt = 0;
|
|
Tcl_Obj *objPtr, *valueObjPtr;
|
|
@@ -1786,7 +1781,6 @@
|
|
if (GetEntryFromObj(tvPtr, objv[3], &entryPtr) != TCL_OK) {
|
|
return TCL_ERROR;
|
|
}
|
|
- node = entryPtr->node;
|
|
string = Tcl_GetString(objv[4]);
|
|
if (Blt_TreeViewGetColumnKey(interp, tvPtr, objv[4], &columnPtr, &left)
|
|
!= TCL_OK || columnPtr == NULL) {
|
|
@@ -1841,7 +1835,6 @@
|
|
Tcl_Obj *CONST *objv;
|
|
{
|
|
TreeViewEntry *entryPtr;
|
|
- Blt_TreeNode node;
|
|
char *key;
|
|
Tcl_Obj *objPtr;
|
|
|
|
@@ -1877,7 +1870,6 @@
|
|
return TCL_OK;
|
|
}
|
|
key = Tcl_GetString(objv[4]);
|
|
- node = entryPtr->node;
|
|
Tcl_Release(entryPtr);
|
|
if (Blt_TreeGetValue(tvPtr->interp, tvPtr->tree, entryPtr->node,
|
|
key, &objPtr) != TCL_OK) {
|
|
@@ -2656,7 +2648,7 @@
|
|
TreeViewEntry *entryPtr;
|
|
char *string;
|
|
int isRoot, isTest;
|
|
- int x, y, wx, wy;
|
|
+ int x, y;
|
|
int rootX, rootY;
|
|
|
|
Tk_GetRootCoords(tvPtr->tkwin, &rootX, &rootY);
|
|
@@ -2693,8 +2685,6 @@
|
|
(Tcl_GetIntFromObj(interp, objv[3], &y) != TCL_OK)) {
|
|
return TCL_ERROR;
|
|
}
|
|
- wx = x;
|
|
- wy = y;
|
|
if (isRoot) {
|
|
x -= rootX;
|
|
y -= rootY;
|
|
@@ -3768,7 +3758,7 @@
|
|
int nMatches, maxMatches, result, length, ocnt, useformat,userow, isvis;
|
|
int depth, maxdepth, mindepth, mask, istree, isleaf, invis, ismap, uselabel;
|
|
int isopen, isclosed, notop, nocase, isfull, cmdLen, docount, optInd, reldepth;
|
|
- int isnull, retLabel, isret, cmdValue;
|
|
+ int isnull, retLabel, isret;
|
|
char *colStr, *keysub;
|
|
Tcl_Obj *cmdObj, *cmdArgs;
|
|
Tcl_Obj **aobjv;
|
|
@@ -3815,7 +3805,6 @@
|
|
reldepth = notop = 0;
|
|
nocase = 0, isfull = 0, useformat = 0;
|
|
keysub = colStr = NULL;
|
|
- cmdValue = 0;
|
|
curValue = NULL;
|
|
cmdObj = NULL;
|
|
cmdArgs = NULL;
|
|
@@ -4663,7 +4652,7 @@
|
|
register int i;
|
|
int length, depth = -1, maxdepth = -1, mindepth = -1, noArgs, usefull = 0;
|
|
int result, nocase, uselabel = 0, optInd, ocnt;
|
|
- char *pattern, *curValue;
|
|
+ char *curValue;
|
|
Blt_List options;
|
|
TreeViewEntry *entryPtr;
|
|
register Blt_ListNode node;
|
|
@@ -4918,7 +4907,6 @@
|
|
!= TCL_OK) {
|
|
goto error; /* This shouldn't happen. */
|
|
}
|
|
- pattern = Blt_ListGetValue(node);
|
|
objPtr = Tcl_GetObjResult(interp);
|
|
result = (*compareProc)(interp, Tcl_GetString(objPtr), kPtr, nocase);
|
|
if (result == invertMatch) {
|
|
@@ -5192,10 +5180,10 @@
|
|
TreeViewColumn *columnPtr;
|
|
TreeViewEntry *entryPtr;
|
|
Tcl_DString dStr;
|
|
- int optSkips, i, m, start, nOptions, inode;
|
|
+ int optSkips, i, m, start, nOptions/*, inode*/;
|
|
|
|
useid = -1;
|
|
- inode = -1;
|
|
+ /*inode = -1;*/
|
|
optSkips = 0;
|
|
sobjc = 0;
|
|
tobjc = 0;
|
|
@@ -5289,7 +5277,7 @@
|
|
}
|
|
addpath:
|
|
node = NULL;
|
|
- inode = -1;
|
|
+ /*inode = -1;*/
|
|
if (oLen == 5
|
|
&& (tvPtr->pathSep == SEPARATOR_NONE || tvPtr->pathSep == NULL)
|
|
&& path[0] == '#' && strcmp(path, "#auto") == 0) {
|
|
@@ -5420,7 +5408,7 @@
|
|
goto error;
|
|
}
|
|
makeent:
|
|
- inode = node->inode;
|
|
+ /*inode = node->inode;*/
|
|
if (Blt_TreeViewCreateEntry(tvPtr, node, 0, options, BLT_CONFIG_OBJV_ONLY) != TCL_OK) {
|
|
goto opterror;
|
|
}
|
|
--- a/generic/bltTreeViewColumn.c
|
|
+++ b/generic/bltTreeViewColumn.c
|
|
@@ -413,7 +413,6 @@
|
|
char *string;
|
|
int objc;
|
|
register int i;
|
|
- Blt_TreeNode node;
|
|
TreeView *tvPtr;
|
|
|
|
string = Tcl_GetString(objPtr);
|
|
@@ -431,7 +430,6 @@
|
|
"\" must be in even name-value pairs", (char *)NULL);
|
|
return TCL_ERROR;
|
|
}
|
|
- node = entryPtr->node;
|
|
tvPtr = entryPtr->tvPtr;
|
|
for (i = 0; i < objc; i += 2) {
|
|
int result;
|
|
@@ -709,11 +707,9 @@
|
|
{
|
|
int n = 0;
|
|
Blt_ChainLink *linkPtr;
|
|
- TreeViewColumn *columnPtr;
|
|
|
|
for (linkPtr = Blt_ChainFirstLink(tvPtr->colChainPtr); linkPtr != NULL;
|
|
linkPtr = Blt_ChainNextLink(linkPtr)) {
|
|
- columnPtr = Blt_ChainGetValue(linkPtr);
|
|
n++;
|
|
}
|
|
return n;
|
|
@@ -2477,7 +2473,7 @@
|
|
Tcl_Obj *CONST *objv;
|
|
{
|
|
TreeViewColumn *colPtr;
|
|
- int width, height;
|
|
+ int width;
|
|
Tk_Anchor anchor;
|
|
int left, right;
|
|
char *string;
|
|
@@ -2508,7 +2504,6 @@
|
|
return TCL_OK;
|
|
}
|
|
width = VPORTWIDTH(tvPtr);
|
|
- height = VPORTHEIGHT(tvPtr);
|
|
|
|
left = tvPtr->xOffset;
|
|
right = tvPtr->xOffset + width;
|
|
@@ -3342,11 +3337,11 @@
|
|
Tcl_IncrRefCount(entryPtr->dataObjPtr);
|
|
}
|
|
} else {
|
|
- Blt_TreeKey key;
|
|
+ /*Blt_TreeKey key;*/
|
|
Tcl_Obj *objPtr;
|
|
int isFmt;
|
|
|
|
- key = tvPtr->sortColumnPtr->key;
|
|
+ /*key = tvPtr->sortColumnPtr->key;*/
|
|
isFmt = Blt_TreeViewStyleIsFmt(tvPtr, tvPtr->sortColumnPtr->stylePtr);
|
|
for(p = tvPtr->flatArr; *p != NULL; p++) {
|
|
TreeViewValue *valuePtr;
|
|
--- a/generic/bltTreeViewStyle.c
|
|
+++ b/generic/bltTreeViewStyle.c
|
|
@@ -1600,15 +1600,13 @@
|
|
int textX, textY, textHeight;
|
|
int gap, columnWidth, ttlWidth;
|
|
int bool;
|
|
- int borderWidth, relief;
|
|
+ /* int borderWidth, relief; */
|
|
TextLayout *textPtr;
|
|
int boxX, boxY, boxWidth, boxHeight;
|
|
TreeViewStyle *csPtr, sRec = *stylePtr;
|
|
int valWidth = (valuePtr->textPtr?valuePtr->width:(icon?TreeViewIconWidth(icon):0));
|
|
- TextLayout *layPtr;
|
|
int showValue;
|
|
|
|
- layPtr = (tvPtr->hideStyleText?NULL:valuePtr->textPtr);
|
|
showValue = (tvPtr->hideStyleText ? 0 : cbPtr->showValue);
|
|
|
|
columnPtr = valuePtr->columnPtr;
|
|
@@ -1617,13 +1615,13 @@
|
|
drawTextBox(tvPtr, drawable, entryPtr, valuePtr, stylePtr, icon, x, y, &sRec);
|
|
gc = sRec.gc;
|
|
|
|
- if (gc != stylePtr->activeGC) {
|
|
+ /* if (gc != stylePtr->activeGC) {
|
|
borderWidth = 0;
|
|
relief = TK_RELIEF_FLAT;
|
|
} else {
|
|
borderWidth = 1;
|
|
relief = TK_RELIEF_RAISED;
|
|
- }
|
|
+ } */
|
|
|
|
columnWidth = columnPtr->width - PADDING(columnPtr->pad);
|
|
if (!valuePtr->string) {
|
|
@@ -2629,15 +2627,10 @@
|
|
TreeViewStyle *csPtr, sRec = *stylePtr;
|
|
int valWidth = (valuePtr->textPtr?valuePtr->width:(icon?TreeViewIconWidth(icon):0));
|
|
double curValue;
|
|
- char *string;
|
|
TextStyle ts;
|
|
XColor *color;
|
|
- TextLayout *layPtr;
|
|
int showValue = (tvPtr->hideStyleText ? 0 : cbPtr->showValue);
|
|
|
|
- layPtr = (tvPtr->hideStyleText?NULL:valuePtr->textPtr);
|
|
-
|
|
- string = NULL;
|
|
textPtr = NULL;
|
|
columnPtr = valuePtr->columnPtr;
|
|
csPtr = columnPtr->stylePtr;
|
|
@@ -3417,7 +3410,6 @@
|
|
{
|
|
TreeViewColumn *columnPtr;
|
|
TreeViewWindowBox *tbPtr = (TreeViewWindowBox *)stylePtr;
|
|
- Tk_Window tkwin;
|
|
int width, height, diff;
|
|
WindowCell *wcPtr;
|
|
TreeViewStyle sRec = *stylePtr;
|
|
@@ -3438,7 +3430,6 @@
|
|
int columnWidth = columnPtr->width -
|
|
(2 * columnPtr->borderWidth + PADDING(columnPtr->pad));
|
|
|
|
- tkwin = wcPtr->tkwin;
|
|
width = columnWidth;
|
|
height = entryPtr->height-1;
|
|
if ((diff = (y-tvPtr->titleHeight- tvPtr->insetY))<0) {
|
|
--- a/generic/bltUnixDnd.c
|
|
+++ b/generic/bltUnixDnd.c
|
|
@@ -1459,6 +1459,7 @@
|
|
*
|
|
* ------------------------------------------------------------------------
|
|
*/
|
|
+#if 0
|
|
static void
|
|
MorphToken(dndPtr)
|
|
Dnd *dndPtr; /* Drag-and-drop manager (source). */
|
|
@@ -1511,6 +1512,7 @@
|
|
}
|
|
RaiseToken(dndPtr);
|
|
}
|
|
+#endif
|
|
|
|
static void
|
|
GetTokenPosition(dndPtr, x, y)
|
|
--- a/generic/bltWinop.c
|
|
+++ b/generic/bltWinop.c
|
|
@@ -913,7 +913,7 @@
|
|
Tk_PhotoHandle srcPhoto;
|
|
Tk_PhotoImageBlock src;
|
|
Blt_ColorImage srcImage;
|
|
- int top, x, y, isalph, iscnt, isNew, cnt;
|
|
+ int x, y, isalph, iscnt, isNew, cnt;
|
|
int i, rng[4], from = 0;
|
|
register Pix32 *srcPtr;
|
|
Tcl_Obj *listPtr;
|
|
@@ -922,7 +922,6 @@
|
|
Blt_HashTable hTbl;
|
|
Blt_HashSearch cursor;
|
|
|
|
- top = 0;
|
|
isalph = 0;
|
|
iscnt = 0;
|
|
while (argc > 3) {
|
|
@@ -1524,7 +1523,7 @@
|
|
{
|
|
double range[3];
|
|
double left[3];
|
|
- int x, y, width;
|
|
+ int x, width;
|
|
double t;
|
|
XColor C;
|
|
XColor *leftPtr, *rightPtr;
|
|
@@ -1554,7 +1553,6 @@
|
|
range[1] = (double)((rightPtr->green - leftPtr->green) / 257.0);
|
|
range[2] = (double)((rightPtr->blue - leftPtr->blue) / 257.0);
|
|
|
|
- y =0;
|
|
for (x = 0; x < width; x++) {
|
|
char cbuf[100];
|
|
t = ((double)( sin(M_PI_2 * (double)x / (double)width)));
|
|
@@ -1574,7 +1572,7 @@
|
|
XColor *leftPtr, *rightPtr;
|
|
double range[3];
|
|
double left[3];
|
|
- int x, y, width;
|
|
+ int x, width;
|
|
double t;
|
|
XColor **destPtr, C;
|
|
|
|
@@ -1587,7 +1585,6 @@
|
|
range[1] = (double)((rightPtr->green - leftPtr->green) / 257.0);
|
|
range[2] = (double)((rightPtr->blue - leftPtr->blue) / 257.0);
|
|
|
|
- y =0;
|
|
width = gradPtr->width;
|
|
if (gradPtr->grads) {
|
|
Blt_FreeGradient(gradPtr);
|
|
--- a/generic/tkButton.c
|
|
+++ b/generic/tkButton.c
|
|
@@ -352,11 +352,9 @@
|
|
char *string, char *widgRec, int offset, char *strList[], char *label )
|
|
{
|
|
int *namePtr = (int *)(widgRec + offset);
|
|
- char c;
|
|
int i;
|
|
|
|
for (i=0; strList[i]; i++) {
|
|
- c = string[0];
|
|
if (strcmp(string, strList[i]) == 0) {
|
|
*namePtr = i;
|
|
return TCL_OK;
|
|
@@ -898,11 +896,10 @@
|
|
{
|
|
Button *butPtr = (Button*)widgRec;;
|
|
int argc = 0;
|
|
- int result, i;
|
|
+ int i;
|
|
char **argv;
|
|
Tk_Image imgs[9], image;
|
|
|
|
- result = TCL_OK;
|
|
if (string && Tcl_SplitList(interp, string, &argc, &argv) != TCL_OK) {
|
|
return TCL_ERROR;
|
|
}
|
|
@@ -1703,7 +1700,7 @@
|
|
Tk_Image image;
|
|
char *oldTextVar = NULL, *oldSelVar = NULL;
|
|
Blt_Tree oldTree;
|
|
- int oldNode, result = TCL_OK;
|
|
+ int result = TCL_OK;
|
|
char * oldABdStr = butPtr->activeBdImageString;
|
|
char * oldDBStr = butPtr->disabledBdImageString;
|
|
char * oldBDStr = butPtr->bdImageString;
|
|
@@ -1712,7 +1709,6 @@
|
|
|
|
winPtr = (Tk_FakeWin *) (butPtr->tkwin);
|
|
oldTree = butPtr->tree;
|
|
- oldNode = butPtr->node;
|
|
|
|
if (oldTree == NULL) {
|
|
oldTextVar = (butPtr->textVarName?strdup(butPtr->textVarName):NULL);
|
|
@@ -2219,7 +2215,7 @@
|
|
* the text to make the button appear to
|
|
* move up and down as the relief changes. */
|
|
Blt_Tile tile, bgTile, inTile;
|
|
- int borderWidth, drawBorder;
|
|
+ int drawBorder;
|
|
int textXOffset, textYOffset;
|
|
int haveImage = 0, haveText = 0;
|
|
int imageWidth, imageHeight;
|
|
@@ -2305,7 +2301,6 @@
|
|
bgTile = TILECHOOSE(bgTile,butPtr->innerTile);
|
|
}
|
|
border = butPtr->normalBorder;
|
|
- borderWidth = butPtr->borderWidth;
|
|
|
|
gc = butPtr->normalTextGC;
|
|
|
|
--- a/generic/bltScrollbar.c
|
|
+++ b/generic/bltScrollbar.c
|
|
@@ -1017,7 +1017,9 @@
|
|
{
|
|
register Scrollbar *scrollPtr = clientData;
|
|
register Tk_Window tkwin = scrollPtr->tkwin;
|
|
+#ifdef notdef
|
|
XPoint points[7];
|
|
+#endif
|
|
Tk_3DBorder border;
|
|
int relief, width, elementBorderWidth;
|
|
Pixmap pixmap;
|
|
--- a/generic/bltTed.c
|
|
+++ b/generic/bltTed.c
|
|
@@ -306,10 +306,14 @@
|
|
static void DisplayTed _ANSI_ARGS_((ClientData clientData));
|
|
static void DestroyTed _ANSI_ARGS_((DestroyData destroyData));
|
|
static void DisplayEntry _ANSI_ARGS_((ClientData clientData));
|
|
+#if 0
|
|
static void DestroyEntry _ANSI_ARGS_((DestroyData destoryData));
|
|
+#endif
|
|
|
|
static Tcl_CmdProc TedCmd;
|
|
+#if 0
|
|
static Tk_EventProc EntryEventProc;
|
|
+#endif
|
|
static Tk_EventProc TedEventProc;
|
|
|
|
/*
|
|
@@ -360,6 +364,7 @@
|
|
*
|
|
*----------------------------------------------------------------------
|
|
*/
|
|
+#if 0
|
|
static void
|
|
EventuallyRedrawEntry(repPtr)
|
|
EntryRep *repPtr; /* Information about editor. */
|
|
@@ -369,6 +374,7 @@
|
|
Tcl_DoWhenIdle(DisplayEntry, repPtr);
|
|
}
|
|
}
|
|
+#endif
|
|
|
|
/*
|
|
* --------------------------------------------------------------
|
|
@@ -387,6 +393,7 @@
|
|
*
|
|
* --------------------------------------------------------------
|
|
*/
|
|
+#if 0
|
|
static void
|
|
EntryEventProc(clientData, eventPtr)
|
|
ClientData clientData; /* Information about window. */
|
|
@@ -408,6 +415,7 @@
|
|
Tcl_EventuallyFree(repPtr, DestroyEntry);
|
|
}
|
|
}
|
|
+#endif
|
|
|
|
/*
|
|
* --------------------------------------------------------------
|
|
@@ -548,6 +556,7 @@
|
|
*
|
|
* ----------------------------------------------------------------------------
|
|
*/
|
|
+#if 0
|
|
static int
|
|
CreateEntry(tedPtr, entryPtr)
|
|
Ted *tedPtr;
|
|
@@ -614,6 +623,7 @@
|
|
}
|
|
}
|
|
}
|
|
+#endif
|
|
|
|
/*
|
|
* ----------------------------------------------------------------------------
|