From b46bdf6e162ca99e89f6d86a2319f87859672671 Mon Sep 17 00:00:00 2001 From: Hans-Christoph Steiner Date: Mon, 29 Oct 2007 18:58:45 +0000 Subject: Following this thread: http://lists.puredata.info/pipermail/pd-dev/2007-10/009797.html I have changed the save functions so that they will save the name of the object that it was actually instantiated with. This allows objects with savefns to work properly with namespaces. This is a fix for this bug: http://sourceforge.net/tracker/index.php?&aid=1818219&group_id=55736&atid=478070 svn path=/trunk/externals/bbogart/; revision=8902 --- popup/popup.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'popup/popup.c') diff --git a/popup/popup.c b/popup/popup.c index cbb3dfc..3529921 100644 --- a/popup/popup.c +++ b/popup/popup.c @@ -376,9 +376,10 @@ static void popup_save(t_gobj *z, t_binbuf *b) int i; t_popup *x = (t_popup *)z; - binbuf_addv(b, "ssiisiiss", gensym("#X"),gensym("obj"), - x->x_obj.te_xpix, x->x_obj.te_ypix , - gensym("popup"), x->x_width, x->x_height, x->x_colour, x->x_name); + binbuf_addv(b, "ssiisiiss", gensym("#X"), gensym("obj"), + x->x_obj.te_xpix, x->x_obj.te_ypix , + atom_getsymbol(binbuf_getvec(x->x_obj.te_binbuf)), + x->x_width, x->x_height, x->x_colour, x->x_name); /* Loop for menu items */ for(i=0 ; ix_num_options ; i++) { @@ -705,7 +706,7 @@ void popup_setup(void) { class_setsavefn(popup_class,&popup_save); #endif - post("Popup v0.1 Ben Bogart.\nCVS: $Revision: 1.17 $ $Date: 2005-06-07 18:09:55 $"); + post("Popup v0.1 Ben Bogart.\nCVS: $Revision: 1.18 $ $Date: 2007-10-29 18:58:42 $"); } -- cgit v1.2.1