[Mono-bugs] [Bug 621475] TextBox and RichTextBox crash on click when text value will be set to null

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Jul 12 20:05:33 EDT 2010


http://bugzilla.novell.com/show_bug.cgi?id=621475

http://bugzilla.novell.com/show_bug.cgi?id=621475#c5


--- Comment #5 from Thomas Goldstein <stifu at free.fr> 2010-07-13 00:05:32 UTC ---
Created an attachment (id=375423)
 --> (http://bugzilla.novell.com/attachment.cgi?id=375423)
Patch

The IndexOutOfRangeException is apparently a caret position bug. As a
workaround, doing textbox.SelectionStart = 0; before resetting the Text avoids
the bug.

Here's a patch to fix the bug. Basically, it applies the same caret updates
whether the Text is null/empty or not.
I hope I can get away with the minor style updates without having to submit
them as a separate patch...

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


More information about the mono-bugs mailing list