これを解決するには、NSTableViewでこのメソッドをオーバーライドします。
@interface NSResponder (NSControlEditingSupport)
/* This is a responder chain method to allow controls to determine when they should become first responder or not. Some controls, such as NSTextField, should only become first responder when the enclosing NSTableView/NSBrowser indicates that the view can begin editing. It is up to the particular control that wants to be validated to call this method in its -mouseDown: (or other time) to determine if it should attempt to become the first responder or not. The default implementation returns YES when there is no -nextResponder, otherwise, it is forwarded up the responder chain. NSTableView/NSBrowser implements this to only allow first responder status if the responder is a view in a selected row. It also delays the first responder assignment if a doubleAction needs to (possibly) be sent. 'event' may be nil if there is no applicable event.
*/
- (BOOL)validateProposedFirstResponder:(NSResponder *)responder forEvent:(NSEvent *)event NS_AVAILABLE_MAC(10_7);
@end
そして、すぐにYESを返して、firstResponderをすばやく作成できるようにします。テーブルは、テキストフィールドがヒットした場合に最初のレスポンダーを作成するのを「遅延」させ、行が最初に選択されない限り、それを作成することを許可しません。