I found a solution to this problem, which is not yet ideal, but I hope that it will soon solve the last issue that I have.
rubymotion, Objective-C Ruby, , Ruby. , Objective-C.
NSTokenField controlTextDidChange NSControl, , . , NSLeftMouseUp, , , Return ( fooobar.com/questions/390846/...). .
Ruby:
def controlTextDidChange(aNotification)
application = NSApplication.sharedApplication
event = application.currentEvent
if event.type == NSLeftMouseUp
e1 = CGEventCreateKeyboardEvent(nil, 0x24, true)
CGEventPost(KCGSessionEventTap, e1)
end
end
, , : , , , , . , , , , .
, , , !
, . tokenField:completionsForSubstring:indexOfToken:indexOfSelectedItem::
selectedIndex[0] = -1