Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16044
Modified Files:
Tag: desiredata
desire.c desire.h kernel.c
Log Message:
introducing gstack_empty()
Index: kernel.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/kernel.c,v
retrieving revision 1.1.2.85
retrieving revision 1.1.2.86
diff -C2 -d -r1.1.2.85 -r1.1.2.86
*** kernel.c 15 Aug 2007 19:22:14 -0000 1.1.2.85
--- kernel.c 17 Aug 2007 08:23:42 -0000 1.1.2.86
***************
*** 247,253 ****
}
! /* deal with several objects bound to the same symbol. If more than one, we
! actually bind a collection object to the symbol, which forwards messages sent
! to the symbol. */
static t_class *bindlist_class;
--- 247,252 ----
}
! /* deal with several objects bound to the same symbol. If more than one,
! we actually bind a collection object to the symbol, which forwards messages sent to the symbol. */
static t_class *bindlist_class;
***************
*** 263,278 ****
#define bind_each(e,x) for (t_bindelem *e = x->list; e; e = e->next)
! static void bindlist_bang(t_bindlist *x) {
! bind_each(e,x) pd_bang(e->who);}
! static void bindlist_float(t_bindlist *x, t_float f) {
! bind_each(e,x) pd_float(e->who, f);}
! static void bindlist_symbol(t_bindlist *x, t_symbol *s) {
! bind_each(e,x) pd_symbol(e->who, s);}
! static void bindlist_pointer(t_bindlist *x, t_gpointer *gp) {
! bind_each(e,x) pd_pointer(e->who, gp);}
! static void bindlist_list(t_bindlist *x, t_symbol *s, int argc, t_atom *argv) {
! bind_each(e,x) pd_list(e->who, s, argc, argv);}
! static void bindlist_anything(t_bindlist *x, t_symbol *s, int argc, t_atom *argv) {
! bind_each(e,x) pd_typedmess(e->who, s, argc, argv);}
static t_bindelem *bindelem_new(t_pd *who, t_bindelem *next) {
--- 262,271 ----
#define bind_each(e,x) for (t_bindelem *e = x->list; e; e = e->next)
! static void bindlist_bang (t_bindlist *x) {bind_each(e,x) pd_bang(e->who);}
! static void bindlist_float (t_bindlist *x, t_float f) {bind_each(e,x) pd_float(e->who,f);}
! static void bindlist_symbol (t_bindlist *x, t_symbol *s) {bind_each(e,x) pd_symbol(e->who,s);}
! static void bindlist_pointer (t_bindlist *x, t_gpointer *gp) {bind_each(e,x) pd_pointer(e->who, gp);}
! static void bindlist_list (t_bindlist *x, t_symbol *s, int argc, t_atom *argv) {bind_each(e,x) pd_list(e->who, s,argc,argv);}
! static void bindlist_anything(t_bindlist *x, t_symbol *s, int argc, t_atom *argv) {bind_each(e,x) pd_typedmess(e->who, s,argc,argv);}
static t_bindelem *bindelem_new(t_pd *who, t_bindelem *next) {
***************
*** 356,361 ****
return 0;
}
! long canvas_base_o_index(void) {
return gstack_head ? gstack_head->base_o_index : 0;
}
--- 349,356 ----
return 0;
}
+
+ int gstack_empty() {return !gstack_head;}
! long canvas_base_o_index() {
return gstack_head ? gstack_head->base_o_index : 0;
}
Index: desire.h
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.h,v
retrieving revision 1.1.2.49.2.44
retrieving revision 1.1.2.49.2.45
diff -C2 -d -r1.1.2.49.2.44 -r1.1.2.49.2.45
*** desire.h 15 Aug 2007 23:34:07 -0000 1.1.2.49.2.44
--- desire.h 17 Aug 2007 08:23:42 -0000 1.1.2.49.2.45
***************
*** 351,353 ****
--- 351,355 ----
EXTERN int pd_stackn;
+ EXTERN int gstack_empty(); /* that's a completely different stack: see pd_pushsym,pd_popsym */
+
#endif /* __DESIRE_H */
Index: desire.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v
retrieving revision 1.1.2.217.2.215
retrieving revision 1.1.2.217.2.216
diff -C2 -d -r1.1.2.217.2.215 -r1.1.2.217.2.216
*** desire.c 17 Aug 2007 07:49:09 -0000 1.1.2.217.2.215
--- desire.c 17 Aug 2007 08:23:38 -0000 1.1.2.217.2.216
***************
*** 663,667 ****
}
! int canvas_isvisible(t_canvas *x) {return !x->loading && canvas_getcanvas(x)->havewindow;}
/* we consider a graph "toplevel" if it has its own window or if it appears as a box in its parent window
--- 663,667 ----
}
! int canvas_isvisible(t_canvas *x) {return gstack_empty() && canvas_getcanvas(x)->havewindow;}
/* we consider a graph "toplevel" if it has its own window or if it appears as a box in its parent window
***************
*** 2083,2092 ****
static t_inlet *canvas_addinlet(t_canvas *x, t_pd *who, t_symbol *s, t_symbol* h) {
t_inlet *ip = inlet_new(x,who,s,0); inlet_settip(ip,h);
! if (!x->loading) canvas_resortinlets(x);
gobj_changed(x,0); return ip;
}
static t_outlet *canvas_addoutlet(t_canvas *x, t_pd *who, t_symbol *s) {
t_outlet *op = outlet_new(x,s);
! if (!x->loading) canvas_resortoutlets(x);
gobj_changed(x,0); return op;
}
--- 2083,2092 ----
static t_inlet *canvas_addinlet(t_canvas *x, t_pd *who, t_symbol *s, t_symbol* h) {
t_inlet *ip = inlet_new(x,who,s,0); inlet_settip(ip,h);
! if (gstack_empty()) canvas_resortinlets(x);
gobj_changed(x,0); return ip;
}
static t_outlet *canvas_addoutlet(t_canvas *x, t_pd *who, t_symbol *s) {
t_outlet *op = outlet_new(x,s);
! if (gstack_empty()) canvas_resortoutlets(x);
gobj_changed(x,0); return op;
}