CylinderCenterSelectedItem Method

Scrolls the Cylinder so that the currently selected item is centered.

Definition

Namespace: BeeMobile.iWheel
Assembly: BeeMobile.iWheel.NET48 (in BeeMobile.iWheel.NET48.dll) Version: 4.8.4.3
C#
public void CenterSelectedItem(
	bool bCenterClosest
)

Parameters

bCenterClosest  Boolean
A System.Bolean.Bolean which can be set to True to center the the currently selected item (pointed to by SelectedIndex) ; false to center the nearest item in the direction of last scrolling.

Remarks

If you scroll the Cylinder using the Scroll(Int32) method then the Cylinder may end up in such a position that the currently selected item is not centered exactly under the cursor. In that case you can call this method in two possible variations:

If you set bCenterClosest to true the item which is the closest to the cursor (i.e., the one which index is SelectedIndex) will be centered.

If you set bCenterClosest to false then the closest item in the direction of last scrolling will be centered.

See Also