NSWindow mouse down fix for first responder

This commit is contained in:
Christopher Lloyd 2011-01-28 11:56:05 -05:00
parent 3cfa9e9b88
commit 347e8ffae1

View File

@ -1918,13 +1918,13 @@ NSString * const NSWindowDidAnimateNotification=@"NSWindowDidAnimateNotification
case NSLeftMouseDown:{
NSView *view=[_backgroundView hitTest:[event locationInWindow]];
if([view acceptsFirstResponder])
[self makeFirstResponder:view];
// Doing this again seems correct for control cells which put a field editor up when they become first responder but I'm not sure
view=[_backgroundView hitTest:[event locationInWindow]];
_mouseDownLocationInWindow=[event locationInWindow];
/* view gets mouse down event before first responder check */
[view mouseDown:event];
if([view acceptsFirstResponder])
[self makeFirstResponder:view];
_mouseDownLocationInWindow=[event locationInWindow];
}
break;