• 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
Need the Why and How of mouseDragged:
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Need the Why and How of mouseDragged:


  • Subject: Need the Why and How of mouseDragged:
  • From: Jerry Krinock <email@hidden>
  • Date: Thu, 13 Dec 2007 06:30:42 -0800

I'm implementing drag and drop in a custom view (i.e., a subclass of NSView). It works if I send dragImage:at:offset:eventpasteboard:source:slideBack: in mouseDown:, except that the only [event type] I ever receive in mouseDown: is NSLeftMouseDown. So I can't distinguish clicks from drags. If I set a drag image unconditionally, the image flashes on the screen if the user only clicks, which is annoying.

It seems that mouseDragged: would be more sensible method from which to send dragImage:at:offset:eventpasteboard:source:slideBack:. But I never get any mouseDragged:messages. Reading the list archives, I get the impression that there might be some kind of trick to getting these, but I can't find the trick.

My mouseDown: method does send -[super mouseDown:] at its conclusion. My custom view is a subview of an RBSplitSubview.

Thanks for any tips,

Jerry Krinock

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Need the Why and How of mouseDragged:
      • From: Alastair Houghton <email@hidden>
  • Prev by Date: Re: Weird Apple Sample code
  • Next by Date: printf
  • Previous by thread: NSViewControllerArray?
  • Next by thread: Re: Need the Why and How of mouseDragged:
  • Index(es):
    • Date
    • Thread