[Mono-bugs] [Bug 643366] [Regression] Scrollbar: "LargeChange" System.ArgumentOutOfRangeException

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Mon Dec 6 02:53:01 EST 2010



--- Comment #7 from Hin-Tak Leung <htl10 at users.sourceforge.net> 2010-12-06 07:53:00 UTC ---
Sorry, here is the working patch (some line-number thing in the last one). 

diff --git a/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ListView.cs
index 52bd32b..f19d144 100644
--- a/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ListView.cs
+++ b/mcs/class/Managed.Windows.Forms/System.Windows.Forms/ListView.cs
@@ -1485,8 +1485,10 @@ namespace System.Windows.Forms

                                if (view == View.Details) {
                                        // Need to update Maximum if using
LargeChange with value other than the visible area
+                  if (v_scroll.Height > (header_control.Height +
item_size.Height)) {
                                        v_scroll.LargeChange = v_scroll.Height
- (header_control.Height + item_size.Height);
                                        v_scroll.Maximum -=
header_control.Height + item_size.Height;
+                    }
                                } else
                                        v_scroll.LargeChange = v_scroll.Height;

Hmm, I can answer my own question about git bisect. It appears that the
questionable commit:

commit f571f51216d2138b8705aeb27a4ebe3aa88e28a2
Author: Carlos Alberto Cortez <calberto.cortez at gmail.com>
Date:   Mon May 10 05:06:12 2010 +0000

    2010-05-09  Carlos Alberto Cortez <calberto.cortez at gmail.com>

        * ListView.cs: Properly adjust SmallChange and LargeChange values for
        our scrollbars depending on the view. Also, update the maximum allowed
        value when setting the values from SetScrollValue to use the already
        available information contained within them.
        Fixes the remaining bits of #543785.

    svn path=/trunk/mcs/; revision=156985

was only in trunk (which became 2.8) and never in 2.6 - and "git log 
mono-2-6-7..2.8 mcs/Managed.Windows.Forms" was misleading to only list 36

Configure bugmail: https://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