aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIOhannes m zmölnig <zmoelnig@users.sourceforge.net>2009-04-08 16:54:38 +0000
committerIOhannes m zmölnig <zmoelnig@users.sourceforge.net>2009-04-08 16:54:38 +0000
commita5d6c6ad14d1ad05b3552739ee7a08fdd26b9ae3 (patch)
treeb5a9bd7153c738f1b7de967a68abe438d350c32c
parent519bc7b58218a83b592d26966ee01d650772e540 (diff)
...
svn path=/trunk/externals/iem/iemguts/; revision=10984
-rw-r--r--src/canvasselect.c16
1 files changed, 13 insertions, 3 deletions
diff --git a/src/canvasselect.c b/src/canvasselect.c
index 53a2a8f..7d0cf12 100644
--- a/src/canvasselect.c
+++ b/src/canvasselect.c
@@ -41,9 +41,18 @@ typedef struct _canvasselect
static void canvasselect_bang(t_canvasselect *x)
{
/* get the selection of the canvas */
+ t_glist*glist=x->x_canvas;
+ t_gobj*obj=NULL;
+ int index=0;
-
-
+ if(NULL==glist) {
+ return;
+ }
+ for(obj=glist->gl_list; obj; obj=obj->g_next, index++) {
+ if(glist_isselected(glist, obj)) {
+ post("selected: %d", index);
+ }
+ }
}
@@ -64,8 +73,9 @@ static int canvasselect_doselect(t_glist*glist, int index)
obj=obj->g_next;
}
- if(obj)
+ if(obj) {
glist_select(glist, obj);
+ }
else {
return -1;
}