Re: NSTrackingRect not always working
Re: NSTrackingRect not always working
- Subject: Re: NSTrackingRect not always working
- From: Quincey Morris <email@hidden>
- Date: Tue, 30 Jul 2013 12:46:55 -0700
On Jul 30, 2013, at 12:25 , Steve Mills <email@hidden> wrote:
> When the timing it just right the view gets a cursorUpdate message, but nothing else. From that point, moving the mouse will not generate mouseMoved messages for the view. Only moving the mouse out of the view and back in will then generate mouseExited, mouseEntered, cursorUpdate, and mouseMoved messages in that order.
You could try specifying the 'NSTrackingAssumeInside' option too. Previously, the documentation for this option was wildly incorrect. It has now been corrected, but it now recommends not using the option, whereas it has always seemed to me that it would be more often wanted than not. It *might* have an effect in the scenario you described.
If that doesn't help, I'd suggest removing the 'NSTrackingActiveInKeyWindow' option, and checking the key window status yourself, rather than trying to get NSTrackingArea to filter your state for you. NSTrackingArea is not as sophisticated as the wealth of options might suggest, and it's often necessary to micro-manage things yourself, even when your app is not active, or your window is not main or key, or whatever.
_______________________________________________
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