[PD-cvs] pd/src desire.c, 1.1.2.125, 1.1.2.126 m_pd.h, 1.4.4.11.2.25, 1.4.4.11.2.26 m_imp.h, 1.3.4.1.2.3, 1.3.4.1.2.4 m_class.c, 1.3.4.7.2.18, 1.3.4.7.2.19
Mathieu Bouchard
matju at users.sourceforge.net
Thu Aug 31 21:36:08 CEST 2006
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30177
Modified Files:
Tag: devel_0_39
desire.c m_pd.h m_imp.h m_class.c
Log Message:
t_propertiesfn removed from DesireData.
Index: m_class.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_class.c,v
retrieving revision 1.3.4.7.2.18
retrieving revision 1.3.4.7.2.19
diff -C2 -d -r1.3.4.7.2.18 -r1.3.4.7.2.19
*** m_class.c 13 Jun 2006 12:48:01 -0000 1.3.4.7.2.18
--- m_class.c 31 Aug 2006 19:36:06 -0000 1.3.4.7.2.19
***************
*** 519,522 ****
--- 519,523 ----
}
+ #ifndef DESIRE
void class_setpropertiesfn(t_class *c, t_propertiesfn f)
{
***************
*** 528,531 ****
--- 529,533 ----
return (c->c_propertiesfn);
}
+ #endif
/* ---------------- the symbol table ------------------------ */
***************
*** 1040,1044 ****
struct _parentwidgetbehavior *c_pwb;
t_savefn c_savefn;
- t_propertiesfn c_propertiesfn;
int c_floatsignalin;
*/
--- 1042,1045 ----
Index: m_pd.h
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_pd.h,v
retrieving revision 1.4.4.11.2.25
retrieving revision 1.4.4.11.2.26
diff -C2 -d -r1.4.4.11.2.25 -r1.4.4.11.2.26
*** m_pd.h 1 Jul 2006 04:20:02 -0000 1.4.4.11.2.25
--- m_pd.h 31 Aug 2006 19:36:06 -0000 1.4.4.11.2.26
***************
*** 501,508 ****
EXTERN void class_setsavefn(t_class *c, t_savefn f);
EXTERN t_savefn class_getsavefn(t_class *c);
! /* prototype for functions to open properties dialogs */
typedef void (*t_propertiesfn)(t_gobj *x, struct _glist *glist);
EXTERN void class_setpropertiesfn(t_class *c, t_propertiesfn f);
EXTERN t_propertiesfn class_getpropertiesfn(t_class *c);
#ifndef PD_CLASS_DEF
--- 501,511 ----
EXTERN void class_setsavefn(t_class *c, t_savefn f);
EXTERN t_savefn class_getsavefn(t_class *c);
!
! #ifndef DESIRE
! /* prototype for functions to open properties dialogs */
typedef void (*t_propertiesfn)(t_gobj *x, struct _glist *glist);
EXTERN void class_setpropertiesfn(t_class *c, t_propertiesfn f);
EXTERN t_propertiesfn class_getpropertiesfn(t_class *c);
+ #endif
#ifndef PD_CLASS_DEF
Index: desire.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v
retrieving revision 1.1.2.125
retrieving revision 1.1.2.126
diff -C2 -d -r1.1.2.125 -r1.1.2.126
*** desire.c 31 Aug 2006 19:02:28 -0000 1.1.2.125
--- desire.c 31 Aug 2006 19:36:05 -0000 1.1.2.126
***************
*** 1507,1540 ****
}
- void garray_properties(t_garray *x);
-
- /* tell GUI to create a properties dialog on the canvas. We tell
- the user the negative of the "pixel" y scale to make it appear to grow
- naturally upward, whereas pixels grow downward. */
- void canvas_properties(t_glist *x) {
- t_gobj *y;
- char graphbuf[200];
- if (glist_isgraph(x) != 0)
- sprintf(graphbuf,
- "pdtk_canvas_dialog %%s %g %g %d %g %g %g %g %d %d %d %d\n",
- 0., 0.,
- 1,
- x->gl_x1, x->gl_y1, x->gl_x2, x->gl_y2,
- (int)x->gl_pixwidth, (int)x->gl_pixheight,
- (int)x->gl_xmargin, (int)x->gl_ymargin);
- else sprintf(graphbuf,
- "pdtk_canvas_dialog %%s %g %g %d %g %g %g %g %d %d %d %d\n",
- glist_dpixtodx(x, 1), -glist_dpixtody(x, 1),
- 0,
- 0., -1., 1., 1.,
- (int)x->gl_pixwidth, (int)x->gl_pixheight,
- (int)x->gl_xmargin, (int)x->gl_ymargin);
- gfxstub_new(&x->gl_pd, x, graphbuf);
- /* if any arrays are in the graph, put out their dialogs too */
- for (y = x->gl_list; y; y = y->g_next)
- if (pd_class(&y->g_pd) == garray_class)
- garray_properties((t_garray *)y);
- }
-
/* called from the gui when "OK" is selected on the canvas properties
dialog. Again we negate "y" scale. */
--- 1507,1510 ----
***************
*** 2204,2229 ****
}
- /* called from graph_dialog to set properties */
- void garray_properties(t_garray *x)
- {
- char cmdbuf[200];
- t_array *a = garray_getarray(x);
- t_scalar *sc = x->x_scalar;
-
- if (!a)
- return;
- gfxstub_deleteforkey(x);
- /* create dialog window. LATER fix this to escape '$'
- properly; right now we just detect a leading '$' and escape
- it. There should be a systematic way of doing this. */
- sprintf(cmdbuf, ((x->x_name->s_name[0] == '$') ?
- "pdtk_array_dialog %%s \\%s %d %d 0\n" :
- "pdtk_array_dialog %%s %s %d %d 0\n"),
- x->x_name->s_name, a->a_n, x->x_saveit +
- 2 * (int)(template_getfloat(template_findbyname(sc->sc_template),
- gensym("style"), x->x_scalar->sc_vec, 1)));
- gfxstub_new(&x->x_gobj.g_pd, x, cmdbuf);
- }
-
/* this is called back from the dialog window to create a garray.
The otherflag requests that we find an existing graph to put it in. */
--- 2174,2177 ----
***************
*** 2234,2240 ****
t_garray *a;
int flags = fflags;
! if (size < 1)
! size = 1;
! if (otherflag == 0 || (!(gl = glist_findgraph(parent))))
gl = glist_addglist(parent, &s_, 0, 1,
(size > 1 ? size-1 : size), -1, 0, 0, 0, 0);
--- 2182,2187 ----
t_garray *a;
int flags = fflags;
! if (size < 1) size = 1;
! if (otherflag == 0 || !(gl = glist_findgraph(parent)))
gl = glist_addglist(parent, &s_, 0, 1,
(size > 1 ? size-1 : size), -1, 0, 0, 0, 0);
***************
*** 5641,5645 ****
class_setwidget(scalar_class, &scalar_widgetbehavior);
class_setsavefn(scalar_class, scalar_save);
! class_setpropertiesfn(scalar_class, scalar_properties);
}
--- 5588,5592 ----
class_setwidget(scalar_class, &scalar_widgetbehavior);
class_setsavefn(scalar_class, scalar_save);
! /*class_setpropertiesfn(scalar_class, scalar_properties);*/
}
***************
*** 8940,8944 ****
}
- static void gatom_properties(t_gobj *z,t_glist *o) {sys_mgui(z,"properties","");}
static void text_getrect(t_gobj *z, t_glist *glist, int *xp1, int *yp1, int *xp2, int *yp2) {
*xp1 = *yp1 = *xp2 = *yp2 = 42; /* desire */
--- 8887,8890 ----
***************
*** 9153,9157 ****
class_addmethod3(c, gatom_set, "set","*");
class_addmethod3(c, gatom_param, "param","*");
- class_setpropertiesfn(c, gatom_properties);
}
--- 9099,9102 ----
***************
*** 9473,9477 ****
class_addmethod3(c, iemgui_label_pos, "label_pos","ff");
class_addmethod3(c, iemgui_label_font, "label_font","*");
- class_setpropertiesfn(c, iemgui_propertiesfn);
}
--- 9418,9421 ----
***************
*** 9501,9511 ****
}
- void iemgui_propertiesfn(t_gobj *x, t_glist *owner)
- {
- // t_symbol *stub = gfxstub_new((t_pd *)x,x,0);
- pd_upload(x);
- // sys_vgui("pdtk_iemgui_dialog %s %x\n", stub->s_name, x);
- }
-
static void iemgui_constrain(t_iemgui *x) {
x->fontsize = MAX(x->fontsize,4);
--- 9445,9448 ----
***************
*** 10447,10451 ****
class_addmethod3(c,glist_menu_open,"menu-open","");
class_addmethod3(c,canvas_map,"map","f");
- class_setpropertiesfn(c, (t_propertiesfn)canvas_properties);
class_addmethod3(c,glist_clear,"clear","");
--- 10384,10387 ----
Index: m_imp.h
===================================================================
RCS file: /cvsroot/pure-data/pd/src/m_imp.h,v
retrieving revision 1.3.4.1.2.3
retrieving revision 1.3.4.1.2.4
diff -C2 -d -r1.3.4.1.2.3 -r1.3.4.1.2.4
*** m_imp.h 21 Oct 2005 13:17:01 -0000 1.3.4.1.2.3
--- m_imp.h 31 Aug 2006 19:36:06 -0000 1.3.4.1.2.4
***************
*** 47,51 ****
--- 47,53 ----
struct _parentwidgetbehavior *c_pwb;/* widget behavior in parent */
t_savefn c_savefn; /* function to call when saving */
+ #ifndef DESIRE
t_propertiesfn c_propertiesfn; /* function to start prop dialog */
+ #endif
int c_floatsignalin; /* onset to float for signal input */
char c_gobj; /* true if is a gobj */
More information about the Pd-cvs
mailing list