mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 15:11:37 +00:00
* Source/NSComboBoxCell.m (validateSelection): Test for invalid row.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@23999 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
6ae514bf25
commit
2436c6b7c5
2 changed files with 16 additions and 8 deletions
|
@ -1,3 +1,7 @@
|
|||
2006-10-30 Matt Rice <ratmice@yahoo.com>
|
||||
|
||||
* Source/NSComboBoxCell.m (validateSelection): Test for invalid row.
|
||||
|
||||
2006-10-28 Adam Fedor <fedor@gnu.org>
|
||||
|
||||
* Source/NSApplication.m (initialize_gnustep_backend): Use
|
||||
|
|
|
@ -697,21 +697,25 @@ static GSComboWindow *gsWindow = nil;
|
|||
{
|
||||
NSText *textObject = nil;
|
||||
id cv = [_cell controlView];
|
||||
int index = [_cell indexOfSelectedItem];
|
||||
|
||||
if ([cv isKindOfClass: [NSControl class]])
|
||||
{
|
||||
textObject = [(NSControl *)cv currentEditor];
|
||||
}
|
||||
|
||||
[_cell setStringValue: [_cell _stringValueAtIndex:
|
||||
[_cell indexOfSelectedItem]]];
|
||||
// Will update the editor when needed
|
||||
if (index != -1)
|
||||
{
|
||||
[_cell setStringValue: [_cell _stringValueAtIndex:
|
||||
[_cell indexOfSelectedItem]]];
|
||||
// Will update the editor when needed
|
||||
|
||||
// FIXME: Because NSCell doesn't behave correctly the line just over has
|
||||
// no effect, to correct this fact, the code below is needed.
|
||||
[textObject setString: [_cell _stringValueAtIndex:
|
||||
[_cell indexOfSelectedItem]]];
|
||||
// End of the code to remove
|
||||
// FIXME: Because NSCell doesn't behave correctly the line just over has
|
||||
// no effect, to correct this fact, the code below is needed.
|
||||
[textObject setString: [_cell _stringValueAtIndex:
|
||||
[_cell indexOfSelectedItem]]];
|
||||
// End of the code to remove
|
||||
}
|
||||
|
||||
if (textObject != nil)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue