On Friday, July 17, 2015, Ken Thomases <k...@codeweavers.com> wrote:

> On Jul 16, 2015, at 8:19 PM, João Varela <joaocvar...@gmail.com
> <javascript:;>> wrote:
> >
> > I’m passing [self bounds]. And no, I am not using NSTrackingInVisibleRect
>
> Why aren't you using that?  That seems like the most obvious way to get
> correct behavior.  The only reason you wouldn't use it is if you were
> adding a tracking area that was only for a portion of a view, but you say
> you're using the view's bounds.


Passing self.bounds it is the simpler case I am using to test this problem.
Indeed I need to create two tracking areas that do not coincide with the
subview's bounds.

That might make the whole issue go away.  (Or it might not.)
>
> Unfortunately it does not solve that, because I tried that option and the
results are the same.


> Does your implementation of -updateTrackingAreas call through to super?
> The docs say it should.  I notice that your coalescing implementation did
> not.


You are right. I included such call to the super at the beginning or at the
end, and yes the same problem remains.


> > Yes, the tracking area is incorrect and apparently I cannot invoke
> -updateTrackingAreas myself because it apparently messes up with the
> NSTrackingArea’s of the subviews and most likely of the clipView, etc.
> >
> > So I guess this problem could be solved if there were a method to tell
> the OS that the tracking areas are invalid (and thus they need to be
> updated). However, apparently there is none, AFAICT. Or is there?
>
> You can't invoke -updateTrackingAreas yourself, but there's nothing
> preventing you from removing old tracking areas and adding new ones, as
> appropriate, any time you like.  You can put that code in a method of your
> own which is called by -updateTrackingAreas plus any other time you want.


Hmm, that I haven't tried. If that works you'll be my hero.

>
> Regards,
> Ken
>

Thanks, João
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to