diff options
author | donal.k.fellows@manchester.ac.uk <dkf> | 2005-11-17 10:57:35 (GMT) |
---|---|---|
committer | donal.k.fellows@manchester.ac.uk <dkf> | 2005-11-17 10:57:35 (GMT) |
commit | 7035fc87adb344a188869752f50282301f73548d (patch) | |
tree | 551a8431a7603d8f0d73f739344653f03f7c3a35 /generic/tkColor.c | |
parent | a73f450fb85d87cd248b7be23ba14bd736956fbc (diff) | |
download | tk-7035fc87adb344a188869752f50282301f73548d.zip tk-7035fc87adb344a188869752f50282301f73548d.tar.gz tk-7035fc87adb344a188869752f50282301f73548d.tar.bz2 |
Lots of ANSIfying of function decls.
Also a few spots where code has been cleaned up more completely.
Diffstat (limited to 'generic/tkColor.c')
-rw-r--r-- | generic/tkColor.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/generic/tkColor.c b/generic/tkColor.c index 2390cb7..0eb80f7 100644 --- a/generic/tkColor.c +++ b/generic/tkColor.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkColor.c,v 1.11 2005/11/04 11:52:50 dkf Exp $ + * RCS: @(#) $Id: tkColor.c,v 1.12 2005/11/17 10:57:35 dkf Exp $ */ #include "tkColor.h" @@ -189,7 +189,7 @@ Tk_GetColor( * suitable for passing to XParseColor). */ { Tcl_HashEntry *nameHashPtr; - int new; + int isNew; TkColor *tkColPtr; TkColor *existingColPtr; TkDisplay *dispPtr = ((TkWindow *) tkwin)->dispPtr; @@ -202,8 +202,8 @@ Tk_GetColor( * First, check to see if there's already a mapping for this color name. */ - nameHashPtr = Tcl_CreateHashEntry(&dispPtr->colorNameTable, name, &new); - if (!new) { + nameHashPtr = Tcl_CreateHashEntry(&dispPtr->colorNameTable, name, &isNew); + if (!isNew) { existingColPtr = (TkColor *) Tcl_GetHashValue(nameHashPtr); for (tkColPtr = existingColPtr; tkColPtr != NULL; tkColPtr = tkColPtr->nextPtr) { @@ -232,7 +232,7 @@ Tk_GetColor( "\"", NULL); } } - if (new) { + if (isNew) { Tcl_DeleteHashEntry(nameHashPtr); } return NULL; @@ -289,7 +289,7 @@ Tk_GetColorByValue( { ValueKey valueKey; Tcl_HashEntry *valueHashPtr; - int new; + int isNew; TkColor *tkColPtr; Display *display = Tk_Display(tkwin); TkDisplay *dispPtr = TkGetDisplay(display); @@ -308,8 +308,8 @@ Tk_GetColorByValue( valueKey.colormap = Tk_Colormap(tkwin); valueKey.display = display; valueHashPtr = Tcl_CreateHashEntry(&dispPtr->colorValueTable, - (char *) &valueKey, &new); - if (!new) { + (char *) &valueKey, &isNew); + if (!isNew) { tkColPtr = (TkColor *) Tcl_GetHashValue(valueHashPtr); tkColPtr->resourceRefCount++; return &tkColPtr->color; |