tweak acceptsFirstResponder

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3467 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Felipe A. Rodriguez 1998-12-16 12:57:41 +00:00
parent 1551c447ac
commit 48d1a0486f

View file

@ -37,7 +37,7 @@
//
// class variables
//
id gnustep_gui_nsbutton_class = nil;
id _nsbuttonCellClass = nil;
//
// NSButton implementation
@ -61,12 +61,12 @@ id gnustep_gui_nsbutton_class = nil;
//
+ (Class)cellClass
{
return gnustep_gui_nsbutton_class;
return _nsbuttonCellClass;
}
+ (void)setCellClass:(Class)classId
{
gnustep_gui_nsbutton_class = classId;
_nsbuttonCellClass = classId;
}
//
@ -85,7 +85,7 @@ id gnustep_gui_nsbutton_class = nil;
[super initWithFrame:frameRect];
// set our cell
[self setCell:[[gnustep_gui_nsbutton_class new] autorelease]];
[self setCell:[[_nsbuttonCellClass new] autorelease]];
return self;
}
@ -288,7 +288,7 @@ id gnustep_gui_nsbutton_class = nil;
//
- (BOOL)acceptsFirstResponder
{
return [cell acceptsFirstResponder] && ([self keyEquivalent] != nil);
return [cell acceptsFirstResponder] || ([self keyEquivalent] != nil);
}
- (void) keyDown: (NSEvent*)theEvent