[Mono-bugs] [Bug 660294] Setting ComboBox.SelectedText to null crashes

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Dec 21 10:14:59 EST 2010


https://bugzilla.novell.com/show_bug.cgi?id=660294

https://bugzilla.novell.com/show_bug.cgi?id=660294#c2


Thomas Goldstein <stifu at free.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |stifu at free.fr

--- Comment #2 from Thomas Goldstein <stifu at free.fr> 2010-12-21 15:14:59 UTC ---
Hey Jerome, thanks for the patch. However, it is not right.
Setting the SelectedText to null is not an action that should be ignored, it
should set the SelectedText to an empty string, as James said.

Let's just borrow the code from the Control.Text property, which works the same
way:


if (value == null) {
value = String.Empty;
}


And while we're there, we should have the following unit test:


comboBox.SelectedText = null;
Assert.AreEqual(String.Empty, comboBox.SelectedText);


I'll take care of this soon.

-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list