selected objects

J

Joe Van Dyk

I have a bunch of shapes in a GnomeCanvas object.

When a user clicks on a Shape, I'd like to select/highlight it and
deselect/unhighlight all other shapes.

So, in my Shape class, I'm catching the click signal and highlighting
the object. I'm not sure how to go about deselecting all the other
Shapes though. Would it make sense to have a class variable in Shapes
that had an array of each Shape and, on a click event, loop through
each Shape and deselect it?

Thanks,
Joe
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,813
Messages
2,569,696
Members
45,480
Latest member
CrazyMember

Latest Threads

Top