When editing of a text field ends after pressing the Return key and no

(other) view has become first responder make the text field itself
first responder by selecting its text just like this is done after
pressing Tab and Shift-Tab.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@30145 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Wolfgang Lux 2010-04-14 07:11:50 +00:00
parent 2a52aa187c
commit 7f6a94c5bb
2 changed files with 11 additions and 2 deletions

View file

@ -1,3 +1,11 @@
2010-04-14 Wolfgang Lux <wolfgang.lux@gmail.com>
* Source/NSTextField.m (-textDidEndEditing:): When editing of a
text field ends after pressing the Return key and no (other) view
has become first responder make the text field itself first
responder by selecting its text just like this is done after
pressing Tab and Shift-Tab.
2010-04-14 Riccardo Mottola <rmottola@users.sf.net>
* Source/NSWindow.m : removed c99-isms

View file

@ -590,9 +590,10 @@ static Class textFieldCellClass;
{
if ([self sendAction: [self action] to: [self target]] == NO)
{
if ([self performKeyEquivalent: [_window currentEvent]] == NO)
[self selectText: self];
[self performKeyEquivalent: [_window currentEvent]];
}
if ([_window firstResponder] == _window)
[self selectText: self];
}
else
{