NSApplication responder chain for arrow keys
问题 I have an NSTextField in my window and 4 menu items with key equivalents ← ↑ → ↓ . When the text field is selected and I press an arrow key, I would expect the cursor to move in the text field but instead the corresponding menu item action is performed. So there has to be an issue in the responder chain. To figure out what's wrong I've watched WWDC 2010 Session 145 – Key Event Handling in Cocoa Applications mentioned in this NSMenuItem KeyEquivalent space " " bug thread. The event flow for