[Mono-bugs] [Bug 425049] ListView: EnsureVisible(>=16) IndexOutOfRangeException

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Sep 22 10:13:42 EDT 2008


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

User calberto.cortez at gmail.com added comment
https://bugzilla.novell.com/show_bug.cgi?id=425049#c7


Carlos Alberto Cortez <calberto.cortez at gmail.com> changed:

           What    |Removed                                         |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                                        |RESOLVED
         Resolution|                                                |FIXED




--- Comment #7 from Carlos Alberto Cortez <calberto.cortez at gmail.com>  2008-09-22 08:13:41 MDT ---
I committed a simpler fix.

As I said, you should not be calling EnsureVisible inside a
BeginUpdate/EndUpdate block. 

At least in .Net, doing so ignores the call to EnsureVisible.

A special case appears when you call EndUpdate *immediately* after
EnsureVisible, and this case, it works. But if you have 3-4 instructions
between them, it's not going to work (EnsureVisible is ignored). I think it
happens that way because EnsureVisible is generating a message and it will take
some time to reach the ListView, and by that time, because of the call to
EndUpdate, it will take it into account. etc. Hopefully you get the idea ;-)

But in *all* the other cases ListView ignores the calls to EnsureVisible inside
the mentioned block. 

Carlos.


-- 
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