Hello,
There is a bug in the ScrollingHelper code, which prevent using it with a RadListBox. This bug is already reporter in PITS :
http://www.telerik.com/support/pits.aspx#/details/Issue=15157
After spending some time understanding the Telerik code, I found what is buggy : the IScrollingInfo wrapper returns wrong values for the scroll viewer viewport, leading to incorrect drag zone calculation.... Moreover, the code calculating the zones seems buggy too.
Please find the correction of the telerik code in order to use the autoscroll feature with RadListBox :
http://www.petit-fichier.fr/2013/06/22/debugautoscrollhorizontal/debugautoscrollhorizontal.rar
I Made little improvements :
- I add a attached Property "Directions" letting users restrict the scroll behavior to horizontal / vertical / or both.
- I add some code in order to let the scroll being a little more natural, by computing a scroll speed factor based on the mouse position.
- I add a little optimization by computing scroll zones only while starting the drag.
However, I have to report some other bugs :
- On the attached sample, there is a bug with the horizontal RadListBox, when the scroll is on the middle, if you select an Item, the RadListBox automatically move the scrollbar and the selected item appaears on the right side of the ListBox... I suspect a buggy behavior of the "BringIntoView" code on the internal PanelHelper class (method MakeVisible)
- Already reported this PITS (http://www.telerik.com/support/pits.aspx#/details/Issue=14454) there is no visual cue for the last selected item... This is really annoying. I hope this Issue could be solved asap.
Bests,
Raphaël.
There is a bug in the ScrollingHelper code, which prevent using it with a RadListBox. This bug is already reporter in PITS :
http://www.telerik.com/support/pits.aspx#/details/Issue=15157
After spending some time understanding the Telerik code, I found what is buggy : the IScrollingInfo wrapper returns wrong values for the scroll viewer viewport, leading to incorrect drag zone calculation.... Moreover, the code calculating the zones seems buggy too.
Please find the correction of the telerik code in order to use the autoscroll feature with RadListBox :
http://www.petit-fichier.fr/2013/06/22/debugautoscrollhorizontal/debugautoscrollhorizontal.rar
I Made little improvements :
- I add a attached Property "Directions" letting users restrict the scroll behavior to horizontal / vertical / or both.
- I add some code in order to let the scroll being a little more natural, by computing a scroll speed factor based on the mouse position.
- I add a little optimization by computing scroll zones only while starting the drag.
However, I have to report some other bugs :
- On the attached sample, there is a bug with the horizontal RadListBox, when the scroll is on the middle, if you select an Item, the RadListBox automatically move the scrollbar and the selected item appaears on the right side of the ListBox... I suspect a buggy behavior of the "BringIntoView" code on the internal PanelHelper class (method MakeVisible)
- Already reported this PITS (http://www.telerik.com/support/pits.aspx#/details/Issue=14454) there is no visual cue for the last selected item... This is really annoying. I hope this Issue could be solved asap.
Bests,
Raphaël.