From 4a4b32ee7dcadb961f7d0feea109a61c92306e47 Mon Sep 17 00:00:00 2001 From: "N.N." Date: Wed, 25 Feb 2004 10:54:43 +0000 Subject: widget tracing backward compatible to tcl8.3 svn path=/trunk/externals/miXed/; revision=1359 --- shared/common/port.c | 12 +++++++----- shared/toxy/scriptlet.c | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) (limited to 'shared') diff --git a/shared/common/port.c b/shared/common/port.c index 556af8f..fa81bc0 100644 --- a/shared/common/port.c +++ b/shared/common/port.c @@ -162,20 +162,22 @@ static int import_obj(t_port *x, char *name) static int import_objarg(t_port *x, char *name) { int ndx = (x->x_inmess[1].a_w.w_symbol == gensym("user") ? 3 : 2); - if (x->x_inatoms > 6) + if (x->x_inatoms > 6 + || (ndx == 3 && x->x_inatoms > 4)) { - t_atom *in = x->x_inmess + 7; - t_atom *out = x->x_outmess; + int nextra; + t_atom *in, *out = x->x_outmess; SETSYMBOL(out, gensym("#X")); out++; SETSYMBOL(out, gensym("obj")); out++; port_setxy(x, ndx, out); binbuf_add(x->x_newbb, 4, x->x_outmess); import_addclassname(x, name, &x->x_inmess[ndx == 2 ? 6 : 2]); out = x->x_outmess; - for (ndx = 7; ndx < x->x_inatoms; ndx++) + for (ndx = 7, nextra = 1, in = x->x_inmess + 7; + ndx < x->x_inatoms; ndx++, nextra++) *out++ = *in++; SETSEMI(out); - binbuf_add(x->x_newbb, x->x_inatoms - 6, x->x_outmess); + binbuf_add(x->x_newbb, nextra, x->x_outmess); x->x_nobj++; return (PORT_NEXT); } diff --git a/shared/toxy/scriptlet.c b/shared/toxy/scriptlet.c index 635c106..9bc312d 100644 --- a/shared/toxy/scriptlet.c +++ b/shared/toxy/scriptlet.c @@ -197,7 +197,7 @@ static char *scriptlet_dedot(t_scriptlet *sp, char *ibuf, char *obuf, if (resolveall) { t_canvas *cv; - if (cv = scriptlet_canvasvalidate(sp, visedonly)) + if (cv = scriptlet_canvasvalidate(sp, 0)) { if (!strncmp(&ibuf[1], "tag", 3)) { -- cgit v1.2.1