Custom cell mouse tracking in an NSTableView?
Custom cell mouse tracking in an NSTableView?
- Subject: Custom cell mouse tracking in an NSTableView?
- From: Jim Correia <email@hidden>
- Date: Tue, 7 Feb 2006 12:04:25 -0500
I am writing a subclass of NSTextFieldCell so I can include a
clickable widget to the right of the text.
The documentation for
- (BOOL)startTrackingAt:(NSPoint)startPoint inView:(NSView *)
controlView;
- (BOOL)continueTracking:(NSPoint)lastPoint at:(NSPoint)currentPoint
inView:(NSView *)controlView;
- (void)stopTracking:(NSPoint)lastPoint at:(NSPoint)stopPoint inView:
(NSView *)controlView mouseIsUp:(BOOL)flag;
says "NSCell’s implementation of -
trackMouse:inRect:ofView:untilMouseUp: invokes this method when
tracking begins".
It stands to reason that NSTextFieldCell may not invoke them (it
appears not to) so I'll have to override -
trackMouse:inRect:ofView:untilMouseUp:.
But to the question... :-)
Suppose the custom cell lives in an NSTableView. The cell's rect
isn't the bounds of controlView. Must I override
trackMouse:inRect:ofView:untilMouseUp: simply to get the bounds of my
cell, or is there a better way?
Thanks,
Jim _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden