From d54b24f46460021e39468261ccf80e74a25a849f Mon Sep 17 00:00:00 2001 From: lecoanet Date: Wed, 15 Jan 2003 12:28:44 +0000 Subject: * (WidgetObjCmd): Rej�te toute tentative de cloner le top groupe --- generic/tkZinc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'generic/tkZinc.c') diff --git a/generic/tkZinc.c b/generic/tkZinc.c index 0a0dd15..0a1d027 100644 --- a/generic/tkZinc.c +++ b/generic/tkZinc.c @@ -2513,7 +2513,7 @@ ZnParseCoordList(WidgetInfo *wi, old_style = (result == ZN_OK); if (old_style) { - if ((num_elems%2) != 0) { + if ((num_elems%2) == 0) { *num_pts = num_elems/2; ZnListAssertSize(wi->work_pts, *num_pts); *pts = p = (ZnPoint *) ZnListArray(wi->work_pts); @@ -3513,7 +3513,8 @@ WidgetObjCmd(ClientData client_data, /* Information about the widget. */ goto error; } result = ZnItemWithTagOrId(wi, args[2], &item, &search_var); - if ((result == ZN_ERROR) || (item == ZN_NO_ITEM)) { + if ((result == ZN_ERROR) || + (item == ZN_NO_ITEM) || (item == wi->top_group)) { goto error; } argc -= 3; -- cgit v1.1