It seems like every single app does this, and it's so ubiquitous, I can't believe there isn't a simple, straight-forward "right" way... so I'm going to assume I'm just being an ***** and can't find it.
Think of Finder (or Xcode,or Sketch, or any number of apps). You have an NSOutlineView, or NSTableView, or whatever... a list of resources in some fashion. You click on a resource (presumably represented by an NSTextField) to select it, then you either click it again, double-click it, or press Enter, and the text field becomes editable, you change the name of the resource, then hit enter, or click away, and it switches back to display mode, and the controller saves the change.
Can anyone point me to the API or a Guide on how to implement this pattern? As I said, it's so common, I find it hard to believe it's not a realtively straight-forward thing to do in Cocoa, but I just cannot seem to find the correct implementation.