• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSFilesPromisePboardType
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSFilesPromisePboardType


  • Subject: Re: NSFilesPromisePboardType
  • From: Olivier <email@hidden>
  • Date: Mon, 16 Sep 2002 13:50:51 -0500

I did call -[NSOutlineView dragPromisedFilesOfTypes:fromRect:source:slideBack:event:] as was advised to me, and it seems to work, i just add to create an outline view category that implements -(NSArray *)namesOfPromisedFilesDroppedAtDestination:(NSURL *)dropDestination and would pass the message to its delegate, but now the problem that i'm facing is that the promised flavor is the only thing that i can drag, i cannot have a multiple flavor drag anymore since the call - (BOOL)dragPromisedFilesOfTypes:(NSArray *)fileTypes fromRect:(NSRect)aRect source:(id)sourceObject slideBack:(BOOL)slideBack event:(NSEvent *)theEvent only return once the item has been dragged.
Basically the way it is implemented force you to have a separate drag for the promised flavor. there is no way to have mixed flavor drag if you need to drag a promised file.

Any idea thought appreciated. Olivier


On Saturday, September 14, 2002, at 06:09 PM, Charles Srstka wrote:

I also wish there was an easy way to write flavorTypePromiseHFS directly to the pasteboard. There doesn't seem to be a way to do this, but I did manage to kludge it by calling -[NSOutlineView dragPromisedFilesOfTypes:fromRect:source:slideBack:event:] in the outlineView:writeItems:toPasteboard: method, and it seems to work.

If there's a better way to do this, I'd really like to know what it is...

Charles

On Saturday, September 14, 2002, at 02:25 PM, Olivier wrote:

I just read the release note of the appkit for 10.2 and was pleased to
discover that Apple created a drag flavor for promise HFS.

So i started to try to use it inside my outline view, but until now
with no luck.
I overwrote the function draggingSourceOperationMaskForLocal of
NSOutlineView so that i can drag to other app, in the delegate i
declare a drag flavor of type NSFilesPromisePboardType.
I implemented the pasteboard delegate method -
(void)pasteboard:(NSPasteboard *)sender provideDataForType:(NSString
*)type but it is not called.

when i do a drag toward the finder, the finder will still not accept
it. Could someone point me in the right direction.

Olivier
_______________________________________________
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.

References: 
 >Re: NSFilesPromisePboardType (From: Charles Srstka <email@hidden>)

  • Prev by Date: Re: limit text input in NSTextView
  • Next by Date: a minor undo/redo question...
  • Previous by thread: Re: NSFilesPromisePboardType
  • Next by thread: [newbie] NSButton change height
  • Index(es):
    • Date
    • Thread