Dragging still not working
Dragging still not working
- Subject: Dragging still not working
- From: Will Price <email@hidden>
- Date: Sat, 19 May 2001 16:44:28 -0700
I have an NSOutlineView. In my outlineView:writeItems:toPasteboard:
method to support dragging, I have the following two lines(only):
[pboard declareTypes:[NSArray arrayWithObjects:NSStringPboardType, nil]
owner:self];
[pboard setString:[NSString stringWithCString:"test"
forType:NSStringPboardType];
If I drag an item from my NSOutlineView to any other application such as
Mail or TextEdit, they do not accept or visibly validate the drag.
I have tried so many things to try to fix this. I've tried adding every
single type in NSPasteboard.h to the declareTypes method for instance.
Note that my own view does accept the drags, and I can get limited
success by adding the Filenames type at which point I can drag to Carbon
apps such as the Finder but no Cocoa apps (yes this is really weird).
What are these other applications looking for?? I'd be happy to provide
it if only someone would reveal the secret. If I drag from Mail or
TextEdit *to* my app, I see that they provide:
NeXT Rich Text Format v1.0 pasteboard type
NSStringPboardType
NeXT smart paste pasteboard type
NeXT plain ascii pasteboard type
CorePasteboardFlavorType 0x52544620
CorePasteboardFlavorType 0x54455854
CorePasteboardFlavorType 0x7374796C
What are these other secret types at the bottom and do I need to provide
them as well for this to work?
Thanks!
-- Will
Will Price, Director of Engineering
PGP Security, Inc.
a division of Network Associates, Inc.