There is an event in swift Cocoa that fires when an NSTextField receives focus for editing. I came from C #, which has GotFocus () and LostFocus () events.
In the NSTextfield field, you can find only those functions that are launched after entering text. Not immediately after receiving focus.
override func controlTextDidBeginEditing(obj: NSNotification) {
}
func control(control: NSControl, textShouldBeginEditing fieldEditor: NSText) -> Bool {
}
I need this because, as soon as someone starts editing, I want to show more details. I have a simpler display name and full name for editing.
Thanks,
source
share