Re: Drag types from iTunes
Re: Drag types from iTunes
- Subject: Re: Drag types from iTunes
- From: email@hidden
- Date: Sun, 3 Mar 2002 06:10:54 -0800
I'm pretty sure all those types you saw on the generalPasteboard were
for text... 0x75747874 is utxt and 0x54455854 is TEXT.
I was surprised to see that they don't put any of the common types on
the pboard.
In my app DropZone, I check for NSStringPboardType,
NSFilenamesPboardType, NSPostScriptPboardType, NSTIFFPboardType,
NSRTFPboardType, NSTabularTextPboardType, NSFontPboardType,
NSRulerPboardType, NSFileContentsPboardType, NSColorPboardType,
NSRTFDPboardType, NSPICTPboardType, NSURLPboardType, NSPDFPboardType,
@"Apple CorePasteboard Fallback Text Script", @"Apple URL pasteboard
type", @"NeXT filename pasteboard type", @"NeXT plain ascii pasteboard
type", @"Apple Uniform Resource Locator (file)", and the
CorePasteboardFlavorType's for 'utxt', 'TEXT', 'node', 'prxy', 'hfs ',
'furl'...
but none of those got a hit from the iTunes drag... the 'hfs ' one
tends to be how Finder drags work...
the contents of the text buffer when you paste it, is a tab separated
row from the faux NSTableView in iTunes.
like this: "Gin and Juice Dr. Dre and Snoop Doggie Dog 3:31 2.9 MB Rap 1/
5/02 8:07 PM 12/30/01 1:01 AM MPEG audio file 112 kbps"
Let us know if you find out what pasteboard iTunes is using to talk to
finder...
On Sunday, March 3, 2002, at 03:05 AM, David Watanabe wrote:
>
Does anyone know how to receive drags from iTunes in an NSView? It
>
must be possible, since the Finder receives drags from iTunes. The
>
problem is, obviously, figuring out what drag types to register the
>
NSView to receive. (Why there is no way to register for all drag types
>
is beyond me).
>
>
In any case, I've tried registering for every defined NS*Type.
>
Investigation into the types iTunes uses when copying (not dragging)
>
yields the types below. Even though the NSStringPboardType looks
>
promising, it's doesn't work (and again, this is copying, and not
>
dragging). Even if I register for any of the obscure types like
>
"CorePasteboardFlavorType 0x75747874", I still cannot receive drags.
>
>
So, does anyone have any idea??
>
>
Thanks,
>
Dave
>
>
[[NSPasteboard generalPasteboard] types] yields the following after
>
copying an item in iTunes:
>
>
<CFArray 0x2391c00 [0x8016024c]>{type = mutable-small, count = 6,
>
values = (
>
0 : <CFString 0x238b340 [0x8016024c]>{contents =
>
"CorePasteboardFlavorType 0x75747874"}
>
1 : <CFString 0x2391c20 [0x8016024c]>{contents = "NeXT plain ascii
>
pasteboard type"}
>
2 : <CFString 0x2391c50 [0x8016024c]>{contents =
>
"CorePasteboardFlavorType 0x54455854"}
>
3 : <CFString 0x2391c90 [0x8016024c]>{contents = "Apple
>
CorePasteboard Fallback Text Script"}
>
4 : NSStringPboardType
>
5 : NSStringPboardType
>
)
>
>
Dave Watanabe
>
sciforums.com | webfansite.com | xlife.org
>
_______________________________________________
>
cocoa-dev mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.