summaryrefslogtreecommitdiffstats
path: root/generic/tkMenuDraw.c
diff options
context:
space:
mode:
authorhobbs <hobbs>2003-11-12 00:07:25 (GMT)
committerhobbs <hobbs>2003-11-12 00:07:25 (GMT)
commitf3c26a85fc9a60851d8901e96fa51034440aed3b (patch)
treebb68b76b97a126e2acb7549639ba354c10b05b6f /generic/tkMenuDraw.c
parent36e65172c3ede415e10dbce6117277a8c1b02560 (diff)
downloadtk-f3c26a85fc9a60851d8901e96fa51034440aed3b.zip
tk-f3c26a85fc9a60851d8901e96fa51034440aed3b.tar.gz
tk-f3c26a85fc9a60851d8901e96fa51034440aed3b.tar.bz2
* generic/tkMenuDraw.c (TkPostSubmenu): add {} around menu name in
case it has spaces when calling Tcl_VarEval. This is a hack until this is rewritten for proper Tcl_Obj handling. [Bug #723856]
Diffstat (limited to 'generic/tkMenuDraw.c')
-rw-r--r--generic/tkMenuDraw.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tkMenuDraw.c b/generic/tkMenuDraw.c
index 0274ac7..ed0cf41 100644
--- a/generic/tkMenuDraw.c
+++ b/generic/tkMenuDraw.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tkMenuDraw.c,v 1.4 2003/05/30 11:03:00 vincentdarley Exp $
+ * RCS: @(#) $Id: tkMenuDraw.c,v 1.5 2003/11/12 00:07:25 hobbs Exp $
*/
#include "tkMenu.h"
@@ -986,7 +986,7 @@ TkPostSubmenu(interp, menuPtr, mePtr)
*/
TkEventuallyRedrawMenu(menuPtr, (TkMenuEntry *) NULL);
- result = Tcl_VarEval(interp, name, " unpost", (char *) NULL);
+ result = Tcl_VarEval(interp, "{", name, "} unpost", (char *) NULL);
menuPtr->postedCascade = NULL;
if (result != TCL_OK) {
return result;
@@ -1009,7 +1009,7 @@ TkPostSubmenu(interp, menuPtr, mePtr)
name = Tcl_GetStringFromObj(mePtr->namePtr, NULL);
Tk_GetRootCoords(menuPtr->tkwin, &x, &y);
AdjustMenuCoords(menuPtr, mePtr, &x, &y, string);
- result = Tcl_VarEval(interp, name, " post ", string, (char *) NULL);
+ result = Tcl_VarEval(interp, "{", name, "} post ", string, (char *) NULL);
if (result != TCL_OK) {
return result;
}