Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv32436
Modified Files: Tag: impd_0_37 g_all_guis.c g_all_guis.h g_bang.c g_dropper.c g_hdial.c g_hslider.c g_mycanvas.c g_numbox.c g_toggle.c g_vumeter.c Log Message: x_isa is dead
Index: g_toggle.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_toggle.c,v retrieving revision 1.1.1.3.2.2.2.12 retrieving revision 1.1.1.3.2.2.2.13 diff -C2 -d -r1.1.1.3.2.2.2.12 -r1.1.1.3.2.2.2.13 *** g_toggle.c 27 Apr 2004 18:09:34 -0000 1.1.1.3.2.2.2.12 --- g_toggle.c 1 May 2004 15:38:35 -0000 1.1.1.3.2.2.2.13 *************** *** 56,60 **** (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, ! gensym("tgl"), x->x_gui.x_w, iem_symargstoint(&x->x_gui.x_isa), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, --- 56,60 ---- (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, ! gensym("tgl"), x->x_gui.x_w, iem_symargstoint(&x->x_gui), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, *************** *** 76,80 **** x->x_gui.x_w, IEM_GUI_MINSIZE, x->x_nonzero, 1.0,/*non_zero-schedule*/ ! x->x_gui.x_isa.x_loadinit, -1, -1,/*no multi*/ srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, --- 76,80 ---- x->x_gui.x_w, IEM_GUI_MINSIZE, x->x_nonzero, 1.0,/*non_zero-schedule*/ ! x->x_gui.x_loadinit, -1, -1,/*no multi*/ srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 144,148 **** static void toggle_loadbang(t_toggle *x) { ! if(!sys_noloadbang && x->x_gui.x_isa.x_loadinit) toggle_fout(x, (float)x->x_on); } --- 144,148 ---- static void toggle_loadbang(t_toggle *x) { ! if(!sys_noloadbang && x->x_gui.x_loadinit) toggle_fout(x, (float)x->x_on); } *************** *** 156,160 ****
static void toggle_init(t_toggle *x, t_floatarg f) ! {x->x_gui.x_isa.x_loadinit = (f==0.0)?0:1;}
static void toggle_nonzero(t_toggle *x, t_floatarg f) --- 156,160 ----
static void toggle_init(t_toggle *x, t_floatarg f) ! {x->x_gui.x_loadinit = (f==0.0)?0:1;}
static void toggle_nonzero(t_toggle *x, t_floatarg f) *************** *** 172,176 **** &a,&isa,&srl[0],&srl[1],&srl[2], &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&on); ! iem_inttosymargs(&x->x_gui.x_isa, isa); x->x_gui.x_font_style = fstyle; iemgui_new_getnames2(&x->x_gui, 2, srl[0], srl[1], srl[2]); --- 172,176 ---- &a,&isa,&srl[0],&srl[1],&srl[2], &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&on); ! iem_inttosymargs(&x->x_gui, isa); x->x_gui.x_font_style = fstyle; iemgui_new_getnames2(&x->x_gui, 2, srl[0], srl[1], srl[2]); *************** *** 183,187 **** iemgui_set_font_style((t_iemgui *)x, x->x_gui.x_font_style); x->x_nonzero = (nonzero!=0.0)?nonzero:1.0; ! x->x_on = x->x_gui.x_isa.x_loadinit ? (on!=0.0)?nonzero:0.0 : 0.0; if (x->x_gui.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv); x->x_gui.x_fontsize = MAX(fs,4); --- 183,187 ---- iemgui_set_font_style((t_iemgui *)x, x->x_gui.x_font_style); x->x_nonzero = (nonzero!=0.0)?nonzero:1.0; ! x->x_on = x->x_gui.x_loadinit ? (on!=0.0)?nonzero:0.0 : 0.0; if (x->x_gui.x_rcv_able) pd_bind(&x->x_gui.x_obj.ob_pd, x->x_gui.x_rcv); x->x_gui.x_fontsize = MAX(fs,4);
Index: g_hdial.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_hdial.c,v retrieving revision 1.1.1.4.2.2.2.13 retrieving revision 1.1.1.4.2.2.2.14 diff -C2 -d -r1.1.1.4.2.2.2.13 -r1.1.1.4.2.2.2.14 *** g_hdial.c 1 May 2004 15:29:58 -0000 1.1.1.4.2.2.2.13 --- g_hdial.c 1 May 2004 15:38:35 -0000 1.1.1.4.2.2.2.14 *************** *** 75,79 **** gensym("hdl") : gensym("hradio")), x->x_gui.x_w, ! x->x_change, iem_symargstoint(&x->x_gui.x_isa), x->x_number, srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, --- 75,79 ---- gensym("hdl") : gensym("hradio")), x->x_gui.x_w, ! x->x_change, iem_symargstoint(&x->x_gui), x->x_number, srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 96,100 **** %s %s %s %d %d %d %d %d %d %d\n", x->x_gui.x_w, IEM_GUI_MINSIZE, 0, ! x->x_change, x->x_gui.x_isa.x_loadinit, -1, x->x_number, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, --- 96,100 ---- %s %s %s %d %d %d %d %d %d %d\n", x->x_gui.x_w, IEM_GUI_MINSIZE, 0, ! x->x_change, x->x_gui.x_loadinit, -1, x->x_number, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 279,283 **** static void hradio_loadbang(t_hradio *x) { ! if(!sys_noloadbang && x->x_gui.x_isa.x_loadinit) hradio_bang(x); } --- 279,283 ---- static void hradio_loadbang(t_hradio *x) { ! if(!sys_noloadbang && x->x_gui.x_loadinit) hradio_bang(x); } *************** *** 304,308 ****
static void hradio_init(t_hradio *x, t_floatarg f) ! {x->x_gui.x_isa.x_loadinit = (f==0.0)?0:1;}
static void hradio_double_change(t_hradio *x) {x->x_change = 1;} --- 304,308 ----
static void hradio_init(t_hradio *x, t_floatarg f) ! {x->x_gui.x_loadinit = (f==0.0)?0:1;}
static void hradio_double_change(t_hradio *x) {x->x_change = 1;} *************** *** 323,327 **** &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&on)) { ! iem_inttosymargs(&x->x_gui.x_isa, isa); iemgui_new_getnames2(&x->x_gui, 4, srl[0], srl[1], srl[2]); } --- 323,327 ---- &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&on)) { ! iem_inttosymargs(&x->x_gui, isa); iemgui_new_getnames2(&x->x_gui, 4, srl[0], srl[1], srl[2]); } *************** *** 336,340 **** x->x_number = num; CLAMP(on,0,x->x_number-1); ! x->x_on = x->x_gui.x_isa.x_loadinit ? on : 0; x->x_on_old = x->x_on; x->x_change = !! chg; --- 336,340 ---- x->x_number = num; CLAMP(on,0,x->x_number-1); ! x->x_on = x->x_gui.x_loadinit ? on : 0; x->x_on_old = x->x_on; x->x_change = !! chg;
Index: g_vumeter.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_vumeter.c,v retrieving revision 1.1.1.3.2.2.2.10 retrieving revision 1.1.1.3.2.2.2.11 diff -C2 -d -r1.1.1.3.2.2.2.10 -r1.1.1.3.2.2.2.11 *** g_vumeter.c 27 Apr 2004 18:09:35 -0000 1.1.1.3.2.2.2.10 --- g_vumeter.c 1 May 2004 15:38:35 -0000 1.1.1.3.2.2.2.11 *************** *** 108,112 **** x->x_gui.x_font_style, x->x_gui.x_fontsize, bflcol[0], bflcol[2], x->x_scale, ! iem_symargstoint(&x->x_gui.x_isa)); binbuf_addv(b, ";"); } --- 108,112 ---- x->x_gui.x_font_style, x->x_gui.x_fontsize, bflcol[0], bflcol[2], x->x_scale, ! iem_symargstoint(&x->x_gui)); binbuf_addv(b, ";"); } *************** *** 155,159 **** iemgui_dialog(&x->x_gui, srl, argc, argv); x->x_gui.x_snd_able = 0; ! x->x_gui.x_isa.x_loadinit = 0; x->x_gui.x_w = iemgui_clip_size(w); vu_check_height(x, h); --- 155,159 ---- iemgui_dialog(&x->x_gui, srl, argc, argv); x->x_gui.x_snd_able = 0; ! x->x_gui.x_loadinit = 0; x->x_gui.x_w = iemgui_clip_size(w); vu_check_height(x, h); *************** *** 215,219 **** int w=IEM_GUI_DEFAULTSIZE, h=IEM_VU_STEPS*IEM_VU_DEFAULTSIZE; int ldx=-1, ldy=-8, fs=8, scale=1; ! iem_inttosymargs(&x->x_gui.x_isa, 0); x->x_gui.x_font_style=0; if(pd_scanargs(argc,argv,"ii??ii?iiii*", --- 215,219 ---- int w=IEM_GUI_DEFAULTSIZE, h=IEM_VU_STEPS*IEM_VU_DEFAULTSIZE; int ldx=-1, ldy=-8, fs=8, scale=1; ! iem_inttosymargs(&x->x_gui, 0); x->x_gui.x_font_style=0; if(pd_scanargs(argc,argv,"ii??ii?iiii*", *************** *** 225,229 **** else iemgui_new_getnames(&x->x_gui, 1, 0); if((argc == 12)&&IS_A_FLOAT(argv,11)) ! iem_inttosymargs(&x->x_gui.x_isa, atom_getintarg(11, argc, argv)); x->x_gui.x_draw = (t_iemfunptr)vu_draw;
--- 225,229 ---- else iemgui_new_getnames(&x->x_gui, 1, 0); if((argc == 12)&&IS_A_FLOAT(argv,11)) ! iem_inttosymargs(&x->x_gui, atom_getintarg(11, argc, argv)); x->x_gui.x_draw = (t_iemfunptr)vu_draw;
Index: g_all_guis.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_all_guis.c,v retrieving revision 1.1.1.4.2.4.2.20 retrieving revision 1.1.1.4.2.4.2.21 diff -C2 -d -r1.1.1.4.2.4.2.20 -r1.1.1.4.2.4.2.21 *** g_all_guis.c 1 May 2004 15:29:57 -0000 1.1.1.4.2.4.2.20 --- g_all_guis.c 1 May 2004 15:38:35 -0000 1.1.1.4.2.4.2.21 *************** *** 385,389 **** &init,&srl[0],&srl[1],&srl[2],&ldx,&ldy,&f,&fs,&bcol,&fcol,&lcol); init = !!init; ! iemgui->x_isa.x_loadinit = init; sndable = strcmp(srl[0]->s_name, "empty"); rcvable = strcmp(srl[1]->s_name, "empty"); --- 385,389 ---- &init,&srl[0],&srl[1],&srl[2],&ldx,&ldy,&f,&fs,&bcol,&fcol,&lcol); init = !!init; ! iemgui->x_loadinit = init; sndable = strcmp(srl[0]->s_name, "empty"); rcvable = strcmp(srl[1]->s_name, "empty"); *************** *** 421,438 **** }
! void iem_inttosymargs(t_iem_init_symargs *symargp, int n) { ! memset(symargp, 0, sizeof(*symargp)); ! symargp->x_loadinit = n>>0; ! symargp->x_scale = n>>20; ! symargp->x_flashed = 0; ! symargp->x_locked = 0; }
! int iem_symargstoint(t_iem_init_symargs *symargp) { return ! (((symargp->x_loadinit & 1) << 0) | ! ((symargp->x_scale & 1) << 20)); }
--- 421,437 ---- }
! void iem_inttosymargs(t_iemgui *self, int n) { ! self->x_loadinit = n>>0; ! self->x_scale = n>>20; ! self->x_flashed = 0; ! self->x_locked = 0; }
! int iem_symargstoint(t_iemgui *self) { return ! (((self->x_loadinit&1) << 0) | ! ((self->x_scale&1) << 20)); }
*************** *** 582,586 **** self->x_ldx=0; self->x_ldy=-6; ! iem_inttosymargs(&self->x_isa, 0); self->x_font_style = 0; self->x_selected = 0; --- 581,585 ---- self->x_ldx=0; self->x_ldy=-6; ! iem_inttosymargs(self,0); self->x_font_style = 0; self->x_selected = 0;
Index: g_mycanvas.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_mycanvas.c,v retrieving revision 1.1.1.3.2.2.2.7 retrieving revision 1.1.1.3.2.2.2.8 diff -C2 -d -r1.1.1.3.2.2.2.7 -r1.1.1.3.2.2.2.8 *** g_mycanvas.c 1 May 2004 15:24:01 -0000 1.1.1.3.2.2.2.7 --- g_mycanvas.c 1 May 2004 15:38:35 -0000 1.1.1.3.2.2.2.8 *************** *** 52,56 **** srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, ! bflcol[0], bflcol[2], iem_symargstoint(&x->x_gui.x_isa)); binbuf_addv(b, ";"); } --- 52,56 ---- srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, ! bflcol[0], bflcol[2], iem_symargstoint(&x->x_gui)); binbuf_addv(b, ";"); } *************** *** 95,99 **** int h = (int)atom_getintarg(3, argc, argv); iemgui_dialog(&x->x_gui, srl, argc, argv); ! x->x_gui.x_isa.x_loadinit = 0; x->x_gui.x_h = x->x_gui.x_w = MAX(a,1); x->x_vis_w = MAX(w,1); --- 95,99 ---- int h = (int)atom_getintarg(3, argc, argv); iemgui_dialog(&x->x_gui, srl, argc, argv); ! x->x_gui.x_loadinit = 0; x->x_gui.x_h = x->x_gui.x_w = MAX(a,1); x->x_vis_w = MAX(w,1); *************** *** 122,126 **** int bflcol[]={~0707070, ~0000000, ~0202020}; int a=IEM_GUI_DEFAULTSIZE, w=100, h=60, ldx=20, ldy=12, i=0, fs=14; ! iem_inttosymargs(&x->x_gui.x_isa, 0); x->x_gui.x_font_style = 0; if(((argc >= 10)&&(argc <= 13)) --- 122,126 ---- int bflcol[]={~0707070, ~0000000, ~0202020}; int a=IEM_GUI_DEFAULTSIZE, w=100, h=60, ldx=20, ldy=12, i=0, fs=14; ! iem_inttosymargs(&x->x_gui, 0); x->x_gui.x_font_style = 0; if(((argc >= 10)&&(argc <= 13)) *************** *** 156,160 **** } if((argc == 13)&&IS_A_FLOAT(argv,i+10)) ! iem_inttosymargs(&x->x_gui.x_isa, atom_getintarg(i+10, argc, argv)); x->x_gui.x_draw = (t_iemfunptr)my_canvas_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent(); --- 156,160 ---- } if((argc == 13)&&IS_A_FLOAT(argv,i+10)) ! iem_inttosymargs(&x->x_gui, atom_getintarg(i+10, argc, argv)); x->x_gui.x_draw = (t_iemfunptr)my_canvas_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent();
Index: g_hslider.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_hslider.c,v retrieving revision 1.1.1.3.2.2.2.16 retrieving revision 1.1.1.3.2.2.2.17 diff -C2 -d -r1.1.1.3.2.2.2.16 -r1.1.1.3.2.2.2.17 *** g_hslider.c 27 Apr 2004 18:39:07 -0000 1.1.1.3.2.2.2.16 --- g_hslider.c 1 May 2004 15:38:35 -0000 1.1.1.3.2.2.2.17 *************** *** 74,78 **** (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, isvert(x) ? gensym("vsl") : gensym("hsl"), x->x_gui.x_w, x->x_gui.x_h, ! (float)x->x_min, (float)x->x_max, x->x_lin0_log1, iem_symargstoint(&x->x_gui.x_isa), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, --- 74,78 ---- (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, isvert(x) ? gensym("vsl") : gensym("hsl"), x->x_gui.x_w, x->x_gui.x_h, ! (float)x->x_min, (float)x->x_max, x->x_lin0_log1, iem_symargstoint(&x->x_gui), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, *************** *** 128,132 **** x->x_gui.x_w, IEM_SL_MINSIZE, x->x_gui.x_h, IEM_GUI_MINSIZE, x->x_min, x->x_max, 0.0,/*no_schedule*/ ! x->x_lin0_log1, x->x_gui.x_isa.x_loadinit, x->x_steady, -1,/*no multi, but iem-characteristic*/ srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, --- 128,132 ---- x->x_gui.x_w, IEM_SL_MINSIZE, x->x_gui.x_h, IEM_GUI_MINSIZE, x->x_min, x->x_max, 0.0,/*no_schedule*/ ! x->x_lin0_log1, x->x_gui.x_loadinit, x->x_steady, -1,/*no multi, but iem-characteristic*/ srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 260,264 ****
static void hslider_init(t_hslider *x, t_floatarg f) ! {x->x_gui.x_isa.x_loadinit = (f==0.0)?0:1;}
static void hslider_steady(t_hslider *x, t_floatarg f) --- 260,264 ----
static void hslider_init(t_hslider *x, t_floatarg f) ! {x->x_gui.x_loadinit = (f==0.0)?0:1;}
static void hslider_steady(t_hslider *x, t_floatarg f) *************** *** 281,285 **** static void hslider_loadbang(t_hslider *x) { ! if(!sys_noloadbang && x->x_gui.x_isa.x_loadinit) { x->x_gui.x_draw(x, x->x_gui.x_glist, 0); --- 281,285 ---- static void hslider_loadbang(t_hslider *x) { ! if(!sys_noloadbang && x->x_gui.x_loadinit) { x->x_gui.x_draw(x, x->x_gui.x_glist, 0); *************** *** 308,312 **** &ldx,&ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&v)) { ! iem_inttosymargs(&x->x_gui.x_isa, isa); iemgui_new_getnames2(&x->x_gui, 6, srl[0], srl[1], srl[2]); } --- 308,312 ---- &ldx,&ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&v)) { ! iem_inttosymargs(&x->x_gui, isa); iemgui_new_getnames2(&x->x_gui, 6, srl[0], srl[1], srl[2]); } *************** *** 319,323 **** x->x_gui.x_draw = (t_iemfunptr)hslider_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent(); ! x->x_val = x->x_gui.x_isa.x_loadinit ? v : 0; x->x_pos = x->x_val; x->x_lin0_log1 = !!lilo; --- 319,323 ---- x->x_gui.x_draw = (t_iemfunptr)hslider_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent(); ! x->x_val = x->x_gui.x_loadinit ? v : 0; x->x_pos = x->x_val; x->x_lin0_log1 = !!lilo;
Index: g_dropper.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/g_dropper.c,v retrieving revision 1.1.2.7 retrieving revision 1.1.2.8 diff -C2 -d -r1.1.2.7 -r1.1.2.8 *** g_dropper.c 28 Apr 2004 20:10:34 -0000 1.1.2.7 --- g_dropper.c 1 May 2004 15:38:35 -0000 1.1.2.8 *************** *** 65,69 **** (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, gensym("dropper"), x->x_gui.x_w, ! iem_symargstoint(&x->x_gui.x_isa), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, --- 65,69 ---- (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, gensym("dropper"), x->x_gui.x_w, ! iem_symargstoint(&x->x_gui), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 86,90 **** %s %s %s %d %d %d %d %d %d %d\n", x->x_gui.x_w, IEM_GUI_MINSIZE, 0, ! -1, x->x_gui.x_isa.x_loadinit, -1, -1, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, --- 86,90 ---- %s %s %s %d %d %d %d %d %d %d\n", x->x_gui.x_w, IEM_GUI_MINSIZE, 0, ! -1, x->x_gui.x_loadinit, -1, -1, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 119,123 **** &ldx,&ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2])) { ! iem_inttosymargs(&x->x_gui.x_isa, isa); iemgui_new_getnames2(&x->x_gui, 2, srl[0], srl[1], srl[2]); } --- 119,123 ---- &ldx,&ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2])) { ! iem_inttosymargs(&x->x_gui, isa); iemgui_new_getnames2(&x->x_gui, 2, srl[0], srl[1], srl[2]); } *************** *** 142,146 **** x->x_gui.x_h = x->x_gui.x_w = iemgui_clip_size(a); iemgui_all_colfromload(&x->x_gui, bflcol); ! x->x_gui.x_isa.x_locked = 0; iemgui_verify_snd_ne_rcv(&x->x_gui); outlet_new(&x->x_gui.x_obj, &s_symbol); --- 142,146 ---- x->x_gui.x_h = x->x_gui.x_w = iemgui_clip_size(a); iemgui_all_colfromload(&x->x_gui, bflcol); ! x->x_gui.x_locked = 0; iemgui_verify_snd_ne_rcv(&x->x_gui); outlet_new(&x->x_gui.x_obj, &s_symbol);
Index: g_bang.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_bang.c,v retrieving revision 1.1.1.3.2.2.2.16 retrieving revision 1.1.1.3.2.2.2.17 diff -C2 -d -r1.1.1.3.2.2.2.16 -r1.1.1.3.2.2.2.17 *** g_bang.c 1 May 2004 15:29:58 -0000 1.1.1.3.2.2.2.16 --- g_bang.c 1 May 2004 15:38:35 -0000 1.1.1.3.2.2.2.17 *************** *** 56,60 **** (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, gensym("bng"), x->x_gui.x_w, x->x_flashtime_hold, x->x_flashtime_break, ! iem_symargstoint(&x->x_gui.x_isa), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, bflcol[0], bflcol[1], bflcol[2]); --- 56,60 ---- (t_int)x->x_gui.x_obj.te_xpix, (t_int)x->x_gui.x_obj.te_ypix, gensym("bng"), x->x_gui.x_w, x->x_flashtime_hold, x->x_flashtime_break, ! iem_symargstoint(&x->x_gui), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, x->x_gui.x_font_style, x->x_gui.x_fontsize, bflcol[0], bflcol[1], bflcol[2]); *************** *** 90,94 **** x->x_gui.x_w, IEM_GUI_MINSIZE, x->x_flashtime_break, x->x_flashtime_hold, 2, ! -1, x->x_gui.x_isa.x_loadinit, -1, -1, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, --- 90,94 ---- x->x_gui.x_w, IEM_GUI_MINSIZE, x->x_flashtime_break, x->x_flashtime_hold, 2, ! -1, x->x_gui.x_loadinit, -1, -1, srl[0]->s_name, srl[1]->s_name, srl[2]->s_name, x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 116,120 **** { if(!x->x_gui.x_put_in2out) ! {x->x_gui.x_isa.x_locked = 1; clock_delay(x->x_clock_lck, 2);} outlet_bang(x->x_gui.x_obj.ob_outlet); if(x->x_gui.x_snd_able && x->x_gui.x_snd->s_thing) --- 116,120 ---- { if(!x->x_gui.x_put_in2out) ! {x->x_gui.x_locked = 1; clock_delay(x->x_clock_lck, 2);} outlet_bang(x->x_gui.x_obj.ob_outlet); if(x->x_gui.x_snd_able && x->x_gui.x_snd->s_thing) *************** *** 124,131 **** static void bng_bang(t_bng *x) { ! if(x->x_gui.x_isa.x_locked) return; bng_set(x); if(!x->x_gui.x_put_in2out) ! {x->x_gui.x_isa.x_locked = 1; clock_delay(x->x_clock_lck, 2);} outlet_bang(x->x_gui.x_obj.ob_outlet); if(x->x_gui.x_snd_able && x->x_gui.x_snd->s_thing && x->x_gui.x_put_in2out) --- 124,131 ---- static void bng_bang(t_bng *x) { ! if(x->x_gui.x_locked) return; bng_set(x); if(!x->x_gui.x_put_in2out) ! {x->x_gui.x_locked = 1; clock_delay(x->x_clock_lck, 2);} outlet_bang(x->x_gui.x_obj.ob_outlet); if(x->x_gui.x_snd_able && x->x_gui.x_snd->s_thing && x->x_gui.x_put_in2out) *************** *** 133,137 **** } static void bng_bang2(t_bng *x) { ! if(x->x_gui.x_isa.x_locked) return; bng_set(x); bng_bout2(x); --- 133,137 ---- } static void bng_bang2(t_bng *x) { ! if(x->x_gui.x_locked) return; bng_set(x); bng_bout2(x); *************** *** 168,172 ****
static void bng_loadbang(t_bng *x) ! {if(!sys_noloadbang && x->x_gui.x_isa.x_loadinit) {bng_set(x); bng_bout2(x);}}
static void bng_size(t_bng *x, t_symbol *s, int ac, t_atom *av) --- 168,172 ----
static void bng_loadbang(t_bng *x) ! {if(!sys_noloadbang && x->x_gui.x_loadinit) {bng_set(x); bng_bout2(x);}}
static void bng_size(t_bng *x, t_symbol *s, int ac, t_atom *av) *************** *** 184,191 ****
static void bng_init(t_bng *x, t_floatarg f) ! {x->x_gui.x_isa.x_loadinit = (f==0.0)?0:1;} static void bng_tick_hld(t_bng *x) {x->x_flashed = 0;} static void bng_tick_brk(t_bng *x) {} ! static void bng_tick_lck(t_bng *x) {x->x_gui.x_isa.x_locked = 0;}
static void *bng_new(t_symbol *s, int argc, t_atom *argv) --- 184,191 ----
static void bng_init(t_bng *x, t_floatarg f) ! {x->x_gui.x_loadinit = (f==0.0)?0:1;} static void bng_tick_hld(t_bng *x) {x->x_flashed = 0;} static void bng_tick_brk(t_bng *x) {} ! static void bng_tick_lck(t_bng *x) {x->x_gui.x_locked = 0;}
static void *bng_new(t_symbol *s, int argc, t_atom *argv) *************** *** 201,205 **** &a,&fthold,&ftbreak,&isa,&srl[0],&srl[1],&srl[2], &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2]); ! iem_inttosymargs(&x->x_gui.x_isa, isa); x->x_gui.x_font_style = fstyle; iemgui_new_getnames2(&x->x_gui, 4, srl[0], srl[1], srl[2]); --- 201,205 ---- &a,&fthold,&ftbreak,&isa,&srl[0],&srl[1],&srl[2], &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2]); ! iem_inttosymargs(&x->x_gui,isa); x->x_gui.x_font_style = fstyle; iemgui_new_getnames2(&x->x_gui, 4, srl[0], srl[1], srl[2]); *************** *** 216,220 **** bng_check_minmax(x, ftbreak, fthold); iemgui_all_colfromload(&x->x_gui, bflcol); ! x->x_gui.x_isa.x_locked = 0; iemgui_verify_snd_ne_rcv(&x->x_gui); x->x_clock_hld = clock_new(x, (t_method)bng_tick_hld); --- 216,220 ---- bng_check_minmax(x, ftbreak, fthold); iemgui_all_colfromload(&x->x_gui, bflcol); ! x->x_gui.x_locked = 0; iemgui_verify_snd_ne_rcv(&x->x_gui); x->x_clock_hld = clock_new(x, (t_method)bng_tick_hld);
Index: g_numbox.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_numbox.c,v retrieving revision 1.1.1.4.2.2.2.11 retrieving revision 1.1.1.4.2.2.2.12 diff -C2 -d -r1.1.1.4.2.2.2.11 -r1.1.1.4.2.2.2.12 *** g_numbox.c 27 Apr 2004 18:09:34 -0000 1.1.1.4.2.2.2.11 --- g_numbox.c 1 May 2004 15:38:35 -0000 1.1.1.4.2.2.2.12 *************** *** 158,162 **** gensym("nbx"), x->x_gui.x_w, x->x_gui.x_h, (float)x->x_min, (float)x->x_max, ! x->x_lin0_log1, iem_symargstoint(&x->x_gui.x_isa), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, --- 158,162 ---- gensym("nbx"), x->x_gui.x_w, x->x_gui.x_h, (float)x->x_min, (float)x->x_max, ! x->x_lin0_log1, iem_symargstoint(&x->x_gui), srl[0], srl[1], srl[2], x->x_gui.x_ldx, x->x_gui.x_ldy, *************** *** 213,217 **** x->x_gui.x_w, 1, x->x_gui.x_h, 8, x->x_min, x->x_max, 0,/*no_schedule*/ ! x->x_lin0_log1, x->x_gui.x_isa.x_loadinit, -1, x->x_log_height, /*no multi, but iem-characteristic*/ srl[0]->s_name, srl[1]->s_name, --- 213,217 ---- x->x_gui.x_w, 1, x->x_gui.x_h, 8, x->x_min, x->x_max, 0,/*no_schedule*/ ! x->x_lin0_log1, x->x_gui.x_loadinit, -1, x->x_log_height, /*no multi, but iem-characteristic*/ srl[0]->s_name, srl[1]->s_name, *************** *** 353,362 **** static void my_numbox_init(t_my_numbox *x, t_floatarg f) { ! x->x_gui.x_isa.x_loadinit = (f==0.0)?0:1; }
static void my_numbox_loadbang(t_my_numbox *x) { ! if(!sys_noloadbang && x->x_gui.x_isa.x_loadinit) { x->x_gui.x_draw(x, x->x_gui.x_glist, 0); --- 353,362 ---- static void my_numbox_init(t_my_numbox *x, t_floatarg f) { ! x->x_gui.x_loadinit = (f==0.0)?0:1; }
static void my_numbox_loadbang(t_my_numbox *x) { ! if(!sys_noloadbang && x->x_gui.x_loadinit) { x->x_gui.x_draw(x, x->x_gui.x_glist, 0); *************** *** 434,438 **** &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&v)) { ! iem_inttosymargs(&x->x_gui.x_isa, isa); iemgui_new_getnames2(&x->x_gui, 6, srl[0], srl[1], srl[2]); } --- 434,438 ---- &x->x_gui.x_ldx,&x->x_gui.x_ldy,&fstyle,&fs,&bflcol[0],&bflcol[1],&bflcol[2],&v)) { ! iem_inttosymargs(&x->x_gui, isa); iemgui_new_getnames2(&x->x_gui, 6, srl[0], srl[1], srl[2]); } *************** *** 445,449 **** x->x_gui.x_draw = (t_iemfunptr)my_numbox_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent(); ! x->x_val = x->x_gui.x_isa.x_loadinit ? v : 0.0; x->x_lin0_log1 = !!lilo; x->x_log_height = MAX(log_height,10); --- 445,449 ---- x->x_gui.x_draw = (t_iemfunptr)my_numbox_draw; x->x_gui.x_glist = (t_glist *)canvas_getcurrent(); ! x->x_val = x->x_gui.x_loadinit ? v : 0.0; x->x_lin0_log1 = !!lilo; x->x_log_height = MAX(log_height,10);
Index: g_all_guis.h =================================================================== RCS file: /cvsroot/pure-data/pd/src/g_all_guis.h,v retrieving revision 1.1.1.4.2.2.2.17 retrieving revision 1.1.1.4.2.2.2.18 diff -C2 -d -r1.1.1.4.2.2.2.17 -r1.1.1.4.2.2.2.18 *** g_all_guis.h 1 May 2004 15:29:58 -0000 1.1.1.4.2.2.2.17 --- g_all_guis.h 1 May 2004 15:38:35 -0000 1.1.1.4.2.2.2.18 *************** *** 15,19 **** #define IEM_GUI_DRAW_MODE_SELECT 3 #define IEM_GUI_DRAW_MODE_ERASE 4 - #define IS_A_POINTER(atom,index) ((atom+index)->a_type == A_POINTER) #define IS_A_FLOAT(atom,index) ((atom+index)->a_type == A_FLOAT) --- 15,18 ---- *************** *** 21,40 **** #define IS_A_DOLLAR(atom,index) ((atom+index)->a_type == A_DOLLAR) #define IS_A_DOLLSYM(atom,index) ((atom+index)->a_type == A_DOLLSYM) ! ! #define IEM_FSTYLE_FLAGS_ALL 0x007fffff ! #define IEM_INIT_ARGS_ALL 0x01ffffff ! ! #define IEM_GUI_OLD_SND_FLAG 1 ! #define IEM_GUI_OLD_RCV_FLAG 2 #define IEMGUI_MAX_NUM_LEN 32
- typedef struct _iem_init_symargs - { - unsigned int x_loadinit:1; - unsigned int x_scale:1; - unsigned int x_flashed:1; - unsigned int x_locked:1; - } t_iem_init_symargs; - typedef void (*t_iemfunptr)(void *x, t_glist *glist, int mode);
--- 20,29 ---- #define IS_A_DOLLAR(atom,index) ((atom+index)->a_type == A_DOLLAR) #define IS_A_DOLLSYM(atom,index) ((atom+index)->a_type == A_DOLLSYM) ! /*#define IEM_FSTYLE_FLAGS_ALL 0x007fffff*/ ! /*#define IEM_INIT_ARGS_ALL 0x01ffffff*/ ! /*#define IEM_GUI_OLD_SND_FLAG 1*/ ! /*#define IEM_GUI_OLD_RCV_FLAG 2*/ #define IEMGUI_MAX_NUM_LEN 32
typedef void (*t_iemfunptr)(void *x, t_glist *glist, int mode);
*************** *** 47,50 **** --- 36,44 ---- int x_ldx, x_ldy; char x_font[16]; + /* formerly x_isa: */ + unsigned int x_loadinit:1; + unsigned int x_scale:1; + unsigned int x_flashed:1; + unsigned int x_locked:1; /* formerly x_fsf: */ unsigned int x_rcv_able:1, x_snd_able:1, x_selected:1, x_finemoved:1, *************** *** 52,56 **** int x_font_style; int x_fontsize; - t_iem_init_symargs x_isa; int x_fcol, x_bcol, x_lcol; /* foreground, background, label colors */ t_symbol *x_snd, *x_rcv, *x_lab; /* send, receive, label symbols */ --- 46,49 ---- *************** *** 182,187 **** EXTERN int canvas_getdollarzero(void); EXTERN void canvas_getargs(int *argcp, t_atom **argvp); ! EXTERN void iem_inttosymargs(t_iem_init_symargs *symargp, int n); ! EXTERN int iem_symargstoint(t_iem_init_symargs *symargp); EXTERN int pd_scanargs(int argc, t_atom *argv, char *format, ...); EXTERN void pd_upload(t_gobj *self, t_canvas *can); --- 175,180 ---- EXTERN int canvas_getdollarzero(void); EXTERN void canvas_getargs(int *argcp, t_atom **argvp); ! EXTERN void iem_inttosymargs(t_iemgui *symargp, int n); ! EXTERN int iem_symargstoint(t_iemgui *symargp); EXTERN int pd_scanargs(int argc, t_atom *argv, char *format, ...); EXTERN void pd_upload(t_gobj *self, t_canvas *can);