Re: Trouble getting drag and drop to work
Re: Trouble getting drag and drop to work
- Subject: Re: Trouble getting drag and drop to work
- From: Angela Brett <email@hidden>
- Date: Thu, 6 Dec 2001 15:40:42 +1300
HI all,
I tried implementing drag and drop, but I really don't know what I'm
doing. My main controller header subclass is as follows:
@interface MyController : NSObject {
IBOutlet NSImageView* soundWell;
}
MyController is extended from NSObject.... and essentially, I want
the user to be able to drag in files to "soundWell" in Interface
builder, but I don't know what to do to get it working. I've read
all the documentation saying how I should "registerForDraggedTypes"
but it simply doesn't work. Can someone please provide a brief code
snippet?
I think you just need to either check the 'Editable' checkbox for
soundWell in Interface Builder, or put [soundWell setEditable:YES];
somewhere in your code.
The documentation for NSImageView's isEditable method says that the
default value is YES, but when they're created in IB it seems like
they are not editable by default.
--
Angela Brett email@hidden
http://acronyms.co.nz/angela
"Great minds think different."