Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8913
Modified Files: Tag: devel_0_39 m_pd.h Log Message: added support for notices (observer interface). also added class_getfieldindex (to complement class_setfieldnames).
Index: m_pd.h =================================================================== RCS file: /cvsroot/pure-data/pd/src/m_pd.h,v retrieving revision 1.4.4.11.2.8 retrieving revision 1.4.4.11.2.9 diff -C2 -d -r1.4.4.11.2.8 -r1.4.4.11.2.9 *** m_pd.h 6 Oct 2005 07:00:27 -0000 1.4.4.11.2.8 --- m_pd.h 6 Oct 2005 07:57:08 -0000 1.4.4.11.2.9 *************** *** 164,170 **** --- 164,173 ---- struct _gobj *master;/* this struct belongs to a master (but in the tcl impl, it's _part_ of the master) */ struct _gobj *next; /* big hack. this is the donut hole as cut from _gobj */ + /* actual observable */ int dirty; /* bitfield of things we may have to confess (unknown=-1 like "(all)" in the client side) */ int nobs; /* number of spies */ struct _gobj **obs; /* I spy with my little I */ + /* virtual func for observer (not observable... sorry, this is just C) */ + void (*notice)(struct _gobj *x, struct _gobj *origin, int dirty); } t_observable; #endif *************** *** 349,352 **** --- 352,357 ---- #define pd_class(x) (*(x))
+ EXTERN void gobj_notice(t_gobj *x, t_gobj *origin, int dirty); + /* ----------------- pointers ---------------- */ EXTERN void gpointer_init(t_gpointer *gp); *************** *** 462,465 **** --- 467,471 ---- EXTERN void inlet_settip(t_inlet* i,t_symbol* s); EXTERN void class_setfieldnames(t_class *x, const char *s); /* where s is split on spaces and tokenized */ + EXTERN int class_getfieldindex(t_class *x, const char *s);
/* ------------ printing --------------------------------- */