Re: Custom Controls not receiving all NSResponder events
Re: Custom Controls not receiving all NSResponder events
- Subject: Re: Custom Controls not receiving all NSResponder events
- From: David Yamnitsky <email@hidden>
- Date: Mon, 13 Jul 2009 17:39:29 -0400
Thanks Darrin!
I had no idea I had to setup tracking rects, apparently this is new in
leopard, sorry for the the trivial question. However, I do have
another issue. I have a custom view which uses an NSComboBox. In
Motion's HUD I can't enter text in the combo box, I can only select
items from the pull-down list. This seems to be an issue along the
same lines. I noticed that Motion's font chooser for the text tool
uses combo boxes, and those work as expected in the HUD. Is there
something I need to change in the responder chain?
Thanks,
David
On Jul 13, 2009, at 5:00 PM, Darrin Cardani wrote:
On Jul 13, 2009, at 1:45 PM, David Yamnitsky wrote:
Hi all, I'm having some trouble that I'm sure others have
encountered as well. I've found that cocoa views used for custom
FxPlug parameters do not receive all NSResponder events, such as
mouseEntered: and mouseExited: however mouseDown: and mouseUp: do
work. Is there some way that I can get mouseEntered: and
mouseExited: to work?
Have you set up tracking rects? You won't received -mouseEntered:
calls unless you have, as far as I know. If you're just trying to
change the cursor when in an appropriate area, you can use cursor
rects:
[-someNSView addCursorRect:someRect cursor:someCursor]
If you need to do more complex stuff than just changing cursors,
look up the docs for NSTrackingArea in the Cocoa Event Handling Guide:
<http://developer.apple.com/documentation/Cocoa/Conceptual/EventOverview/TrackingAreaObjects/TrackingAreaObjects.html#//apple_ref/doc/uid/10000060i-CH8-SW1
>
Darrin
--
Darrin Cardani
email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Pro-apps-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden