diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-01-08 08:31:34 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2019-01-08 08:31:34 (GMT) |
commit | 1cf82956754b0b42ef212635195b5c29fc93a0fc (patch) | |
tree | b6bf6eaff55be5c6fd20363aea6473c6bfbd76ad /generic/tkScale.c | |
parent | 726546cf2742672ce6de89b0500b3e750c6fe3b7 (diff) | |
parent | d2747a371058fa4128dbd7896fe040f0b3ee6be7 (diff) | |
download | tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.zip tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.tar.gz tk-1cf82956754b0b42ef212635195b5c29fc93a0fc.tar.bz2 |
Fix [9e31fd944934e269121fa78ff56b7b86f33e6db6|9e31fd9449]: X11/X.h and Windows.h have conflicting symbols.
*** POTENTIAL INCOMPATIBILITY *** on Windows only: gcc/clang/MSVC will generate new warnings in extensions when the "None" symbol is used incorrectly.
Those warnings are all fixed in the core, that's what most of this commit is doing.
Diffstat (limited to 'generic/tkScale.c')
-rw-r--r-- | generic/tkScale.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/generic/tkScale.c b/generic/tkScale.c index 69a7d91..6ab574e 100644 --- a/generic/tkScale.c +++ b/generic/tkScale.c @@ -264,11 +264,11 @@ Tk_ScaleObjCmd( scalePtr->activeBorder = NULL; scalePtr->sliderRelief = TK_RELIEF_RAISED; scalePtr->troughColorPtr = NULL; - scalePtr->troughGC = None; - scalePtr->copyGC = None; + scalePtr->troughGC = NULL; + scalePtr->copyGC = NULL; scalePtr->tkfont = NULL; scalePtr->textColorPtr = NULL; - scalePtr->textGC = None; + scalePtr->textGC = NULL; scalePtr->relief = TK_RELIEF_FLAT; scalePtr->highlightWidth = 0; scalePtr->highlightBorder = NULL; @@ -285,7 +285,7 @@ Tk_ScaleObjCmd( scalePtr->vertTroughX = 0; scalePtr->vertLabelX = 0; scalePtr->fontHeight = 0; - scalePtr->cursor = None; + scalePtr->cursor = NULL; scalePtr->takeFocusPtr = NULL; scalePtr->flags = NEVER_SET; @@ -514,13 +514,13 @@ DestroyScale( TCL_GLOBAL_ONLY|TCL_TRACE_WRITES|TCL_TRACE_UNSETS, ScaleVarProc, (ClientData) scalePtr); } - if (scalePtr->troughGC != None) { + if (scalePtr->troughGC != NULL) { Tk_FreeGC(scalePtr->display, scalePtr->troughGC); } - if (scalePtr->copyGC != None) { + if (scalePtr->copyGC != NULL) { Tk_FreeGC(scalePtr->display, scalePtr->copyGC); } - if (scalePtr->textGC != None) { + if (scalePtr->textGC != NULL) { Tk_FreeGC(scalePtr->display, scalePtr->textGC); } Tk_FreeConfigOptions((char *) scalePtr, scalePtr->optionTable, @@ -727,7 +727,7 @@ ScaleWorldChanged( gcValues.foreground = scalePtr->troughColorPtr->pixel; gc = Tk_GetGC(scalePtr->tkwin, GCForeground, &gcValues); - if (scalePtr->troughGC != None) { + if (scalePtr->troughGC != NULL) { Tk_FreeGC(scalePtr->display, scalePtr->troughGC); } scalePtr->troughGC = gc; @@ -735,12 +735,12 @@ ScaleWorldChanged( gcValues.font = Tk_FontId(scalePtr->tkfont); gcValues.foreground = scalePtr->textColorPtr->pixel; gc = Tk_GetGC(scalePtr->tkwin, GCForeground | GCFont, &gcValues); - if (scalePtr->textGC != None) { + if (scalePtr->textGC != NULL) { Tk_FreeGC(scalePtr->display, scalePtr->textGC); } scalePtr->textGC = gc; - if (scalePtr->copyGC == None) { + if (scalePtr->copyGC == NULL) { gcValues.graphics_exposures = False; scalePtr->copyGC = Tk_GetGC(scalePtr->tkwin, GCGraphicsExposures, &gcValues); |