Hi there,
I'm trying to set the focus ring on a 10.4 NSBrowser column for a drag
in. I'v tried setting it on the NSMatrix of each column but the focus
ring stops where the NSMatrix view stops. So I've sub-classed my
NSBrower as such:
- (BOOL)needsDisplay;
{
NSResponder* resp = nil;
shouldDrawFocusRing = (resp != nil && [resp isKindOfClass:[NSView
class]]
&& [(NSView*)resp
isDescendantOf:self]);
lastResp = resp;
[self setKeyboardFocusRingNeedsDisplayInRect:[[AppController
sharedInstance]rectInColumn:0]];
return YES;
}
- (void)drawRect:(NSRect)rect
{
[super drawRect:[[AppController sharedInstance]rectInColumn:0]];
if ( shouldDrawFocusRing )
{
NSSetFocusRingStyle(NSFocusRingOnly);
NSRectFill([[AppController sharedInstance]rectInColumn:0]);
}
}
[[AppController sharedInstance]rectInColumn:0] being the NSRect of the
column. I've chosen column:0 just for testing purposes
However the NSBrowser still draws its focus ring around its entire view.
Any help greatly appreciated.
_______________________________________________
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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [EMAIL PROTECTED]