diff options
author | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2007-11-14 03:51:35 +0000 |
---|---|---|
committer | Hans-Christoph Steiner <eighthave@users.sourceforge.net> | 2007-11-14 03:51:35 +0000 |
commit | b0114d623806df53bce55158e4ef89d62648da68 (patch) | |
tree | 94261d8e1af36e692ef54fff1f610e2e0bd48a6a /shared/tkwidgets.c | |
parent | 3afde3d7dbb730999164405ce1e781ef35e66465 (diff) |
got a quick working example pretty much straight from ggee's image.c; I need to get the shared dylib working before working on a new objectclass
svn path=/trunk/externals/tkwidgets/; revision=9002
Diffstat (limited to 'shared/tkwidgets.c')
-rw-r--r-- | shared/tkwidgets.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/shared/tkwidgets.c b/shared/tkwidgets.c index 13fe311..6439842 100644 --- a/shared/tkwidgets.c +++ b/shared/tkwidgets.c @@ -22,6 +22,7 @@ #include "tkwidgets.h" #include <stdio.h> +#include <string.h> /* this should be part of the Pd API */ t_symbol *canvas_getname(t_canvas *canvas) @@ -31,6 +32,21 @@ t_symbol *canvas_getname(t_canvas *canvas) return gensym(buf); } +/* +I think I'll probably have to follow Krzsztof and make structs to make this work +tkwidgets_setcallbackname(void *x, char *widget_name) +{ + char buf[MAXPDSTRING]; + + sprintf(buf,"%s%lx", widget_name, (long unsigned int)x); + x->tcl_namespace = getbytes(strlen(buf)); + strcpy(x->tcl_namespace, buf); + + sprintf(buf,"#%s", x->tcl_namespace); + x->receive_name = gensym(buf); + pd_bind(&x->x_obj.ob_pd, x->receive_name); +} +*/ void draw_inlets(t_object *x, t_glist *glist, int firsttime, int total_inlets, int total_outlets) |