Re: Calling commitEditing text field loses focus

Kyle Sluder <[email protected]> Tue, 20 Dec 2011 15:49:06 -0800
Newsgroups gmane.comp.macosx.devel
Message-ID <CANEs-cyPNf8TbNdkMf5X3sSBb0F9GD6V1VKdVC04Hkw60VM-Tg@mail.gmail.com>
On Tue, Dec 20, 2011 at 1:41 PM, Christiaan Hofman <[email protected]> wrote:
>
> On Dec 20, 2011, at 21:50, Kyle Sluder wrote:
>
>> Try using -commitEditingAndReturnError: (new in 10.7) instead?
>>
>> --Kyle Sluder
>
> Not relevant, I support 10.5. Moreover, why would or should returning an error change this behavior?

It's not "returning an error" that would change the behavior. That
method was added to support autosaving in Lion, which you probably
wouldn't want to disturb the responder chain at random times even if
it was successful. Now that that method exists, it could be possible
that the behavior of NSTextField's -commitEditing was changed to give
up first responder. That's why I suggested you try it.

--Kyle Sluder