Matrix of NSImageCells, selection and dragging
Matrix of NSImageCells, selection and dragging
- Subject: Matrix of NSImageCells, selection and dragging
- From: Gideon King <email@hidden>
- Date: Wed, 8 Jul 2009 21:11:23 +1000
Hi, I need do achieve the following scenario:
- a matrix of images
- multiple selection of the images (including discontiguous selection)
- dragging the selected images out (but not dragging images in)
My thought was that I could use an NSMatrix with NSImageCells, but my
initial test by putting it together in IB was somewhat less than
successful because when I clicked the image, it replaced it with a
description of the image, and then when I tried to click elsewhere to
deselect, the program crashed trying to set the cell's value to
something other than an image.
Is there already a component out there that does all or some of what I
describe above? I wouldn't be surprised if others have needed to do
similar things before.
Is the concept of using an NSMatrix with NSImageCells going to get me
there quicker that writing my own class? After all, it appears that
using this approach, I will still probably have to override the matrix
to draw its border the way I want (I don't think grouping it in a box
is going to quite get me there), and override the drawing of the
selection, and override the acceptance of dropped images and add
dragging out, and add support for dragging a collection of images at
once.
Thanks
Gideon
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden