• 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
Drag and Drop
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Drag and Drop


  • Subject: Drag and Drop
  • From: klee04 <email@hidden>
  • Date: Thu, 18 Nov 2004 17:07:41 +0900

Hi,

 

I found weird problem with Drag and Drop code.  When I power on my Macintosh and run my application, drag and drop does not work.  Although, mouse clicked event to start the drag gets called, mouse dragging event does not seem to get reported, and I cannot validate and accept drop.  However, when I run some other application (any other drag and drop application), and then run my app, the drag and drop starts to work.  This only happens when I reboot my computer.  Does anybody know why this is happening?  I do register my drag and drop type as shown below:

 

[outlineView registerForDraggedTypes:[NSArray arrayWithObjects:NSStringPboardType, NSFilenamesPboardType, nil]];

 

This function gets called:

 

- (BOOL)outlineView:(NSOutlineView *)outlineView writeItems:(NSArray *)items toPasteboard:(NSPasteboard *)pboard

 

 

But not these:

- (unsigned int)outlineView:(NSOutlineView*)ftView validateDrop:(id <NSDraggingInfo>)info proposedItem:(id)item proposedChildIndex:(int)childIndex

- (BOOL)outlineView:(NSOutlineView*)ftView acceptDrop:(id <NSDraggingInfo>)info item:(id)targetItem childIndex:(int)childIndex

 

 

Any help would be greatly appreciated.

 

Thanks.

 

Kanghoon Lee

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Drag and Drop
      • From: stephane sudre <email@hidden>
  • Prev by Date: Re: Replacing characters of a string
  • Next by Date: Re: Swapping views and autoresizing ....
  • Previous by thread: Re: Replacing characters of a string
  • Next by thread: Re: Drag and Drop
  • Index(es):
    • Date
    • Thread