• 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: Odd interaction of NSTrackingArea behaviour with drag and drop [BUG?]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Odd interaction of NSTrackingArea behaviour with drag and drop [BUG?]


  • Subject: Re: Odd interaction of NSTrackingArea behaviour with drag and drop [BUG?]
  • From: Luke Evans <email@hidden>
  • Date: Wed, 11 Mar 2009 12:52:10 -0700

Well, further playing strongly suggests this is a bug to me (and I'll log it as such).

The stuttering ...mouseEntered-mouseExited...mouseEntered- mouseExited... events as you drag within a single tracking area happen even in the simplest NSView:
http://idisk.mac.com/luke_e-Public/TrackingTesterDragDrop2.zip
(58KB)


The frequency at which the paired events arrive, for essentially a constant velocity of mouse movement seems to vary. Sometimes, you get very regular events tracking the mouse left-to-right, and only very occasional events tracking right-to-left, sometimes its 'smooth' (but still paired out-in) in both directions, or very sketchy in any direction. This is pure conjecture, but it's almost as if you intersect with some other event stream generated periodically internally (like the thing that generates "draggingUpdated" events every 50/60 ms or so, and where the generation of mouse events occur with relation to this determines whether you'll get mouseExit- mouseEntered emitted, and whether they have a constant period (perhaps when you happen to get 'in between' the periodic drag events) or not. It certainly looks like there are some kinds of timing boundaries that are interacting.

There are no mouseDragged events sent while you drag over the tracking area (though the window for them arriving is minimal as the tracking stuff ends each pair with "mouseExited").

It looks like I'm going to have to code a parallel hit-testing mechanism for when the user is dragging items in from another app. Unless there's some magic here, the NSTrackingArea stuff that handles this in all other situations is simply gaga in this case.

-- lwe



On 10-Mar-09, at 8:43 PM, Luke Evans wrote:

For the curious, the test app is available at:
http://idisk.mac.com/luke_e-Public/TrackingTesterDragDrop.zip
(61.2 KB)

On 10-Mar-09, at 7:41 PM, Luke Evans wrote:
I have a test app that recreates the problem in what I consider a reasonably sterile environment..


_______________________________________________

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


References: 
 >Odd interaction of NSTrackingArea behaviour with drag and drop (From: Luke Evans <email@hidden>)
 >Re: Odd interaction of NSTrackingArea behaviour with drag and drop (From: Luke Evans <email@hidden>)

  • Prev by Date: Re: Time Zone Names
  • Next by Date: Re: Time Zone Names
  • Previous by thread: Re: Odd interaction of NSTrackingArea behaviour with drag and drop
  • Next by thread: Examples or Documentation for Non-document-based Multi-window App
  • Index(es):
    • Date
    • Thread