• 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: Delaying a drag event
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Delaying a drag event


  • Subject: Re: Delaying a drag event
  • From: j o a r <email@hidden>
  • Date: Fri, 25 Jun 2004 13:39:06 -0700

I don't understand what you're saying. Keeping the mouse button pressed
should not, AFAIK, turn the event into a drag event. You should have to
move the mouse while keeping the mouse button pressed in order to have
the event interpreted as a drag event. You probably also need to move
the mouse a certain distance in order for it to be treated as a drag
event.

Are you simply implementing "mouseDragged:" to watch for mouse dragged
events, or are you implementing your own event loop in "mouseDown:"? If
you're implementing your own event loop, consider checking for the
offset of the mouse pointer relative to the original mouse event, and
avoid treating the event as a drag event unless the offset is larger
than a certain delta, for example 5 pixels.

j o a r

On 2004-06-25, at 13.06, Rick Bischoff wrote:

> In my application I have two different functions performed depending
> on a mouse down or a drag-- however, there are times when the user
> hits the mouse button down for just a split second too long and it is
> then interpreted as a drag. Is there anyway to increase this
> threshold?

[demime 0.98b removed an attachment of type application/pkcs7-signature which had a name of smime.p7s]
_______________________________________________
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: 
 >Delaying a drag event (From: Rick Bischoff <email@hidden>)

  • Prev by Date: Custom View usage in Interface Builder
  • Next by Date: Re: Dynamic User Interface with Cocoa
  • Previous by thread: Delaying a drag event
  • Next by thread: NSMutableDictionary member access problem
  • Index(es):
    • Date
    • Thread