Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2225
Modified Files: Tag: devel_0_39 desire.c Log Message: a lot of confusion
Index: desire.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v retrieving revision 1.1.2.90 retrieving revision 1.1.2.91 diff -C2 -d -r1.1.2.90 -r1.1.2.91 *** desire.c 3 Jul 2006 03:26:03 -0000 1.1.2.90 --- desire.c 4 Jul 2006 20:56:35 -0000 1.1.2.91 *************** *** 445,448 **** --- 445,449 ---- void canvas_rename(t_canvas *x, t_symbol *s, t_symbol *dir) { + post("canvas_rename"); if (strcmp(x->gl_name->s_name, "Pd")) pd_unbind(&x->gl_pd, canvas_makebindsym(x->gl_name)); x->gl_name = s; *************** *** 1080,1085 **** } canvas_pop(x, x->gl_willvis); ! ! if (!(z = gensym("#X")->s_thing)) error("canvas_restore: out of context"); else if (*z != canvas_class) error("canvas_restore: wasn't a canvas"); else --- 1081,1086 ---- } canvas_pop(x, x->gl_willvis); ! z = gensym("#X")->s_thing; ! if (!z) error("canvas_restore: out of context"); else if (*z != canvas_class) error("canvas_restore: wasn't a canvas"); else *************** *** 6617,6620 **** --- 6618,6622 ---- } } + static void canvas_saveto(t_canvas *x, t_binbuf *b) { t_gobj *y; *************** *** 10763,10767 **** t_text *x = (t_text *)pd_new(text_class); t_atom at; ! sys_vgui("global _; set _(%x:canvas) %lx\n",(long)x,(long)gl); x->te_width = 0; x->te_type = T_TEXT; --- 10765,10769 ---- t_text *x = (t_text *)pd_new(text_class); t_atom at; ! sys_vgui("global _; set _(x%x:canvas) %lx\n",(long)x,(long)gl); x->te_width = 0; x->te_type = T_TEXT; *************** *** 10815,10819 **** } if (!x) x = (t_text *)pd_new(text_class); ! sys_vgui("global _; set _(%x:canvas) %lx\n",(long)x,(long)gl); x->te_binbuf = b; x->te_xpix = xpix; --- 10817,10821 ---- } if (!x) x = (t_text *)pd_new(text_class); ! sys_vgui("global _; set _(x%x:canvas) %lx\n",(long)x,(long)gl); x->te_binbuf = b; x->te_xpix = xpix; *************** *** 11282,11286 ****
void text_save(t_gobj *z, t_binbuf *b) { - fprintf(stderr,"text_save %p\n",z); t_text *x = (t_text *)z; if (x->te_type == T_OBJECT) { --- 11284,11287 ---- *************** *** 11297,11301 **** (t_int)x->te_xpix, (t_int)x->te_ypix); } ! binbuf_addbinbuf(b, x->te_binbuf); binbuf_addv(b, ";"); } else if (x->te_type == T_MESSAGE) { --- 11298,11306 ---- (t_int)x->te_xpix, (t_int)x->te_ypix); } ! if (x->te_binbuf) { ! binbuf_addbinbuf(b, x->te_binbuf); ! } else { ! bug("binbuf missing at #X restore !!!"); ! } binbuf_addv(b, ";"); } else if (x->te_type == T_MESSAGE) { *************** *** 11643,11655 **** /* just the "#N canvas" line, not the contents */ canvas_savecontainerto((t_canvas *)self,buf); - } else { - c->c_savefn(self,buf); } binbuf_gettext(buf,&s,&n); if (s[n-1]=='\n') n--; ! //sys_vgui("update_object x%lx {%.*s}\n", (long)self,n,s); ! sys_vgui("update_object x%lx {%.*s} %d %d\n", (long)self,n,s,obj_ninlets((t_text *)self),obj_noutlets((t_text *)self)); ! sys_mgui(self,"ninlets=" ,"i", obj_ninlets((t_text *)self)); ! sys_mgui(self,"noutlets=","i",obj_noutlets((t_text *)self)); binbuf_free(buf); free(s); --- 11648,11659 ---- /* just the "#N canvas" line, not the contents */ canvas_savecontainerto((t_canvas *)self,buf); } + c->c_savefn(self,buf); binbuf_gettext(buf,&s,&n); if (s[n-1]=='\n') n--; ! sys_vgui("update_object x%lx {%.*s} %d %d\n", ! (long)self,n,s, ! obj_ninlets((t_text *)self), ! obj_noutlets((t_text *)self)); binbuf_free(buf); free(s);