ScrollService
Converts pointer drags into scrollbar value changes and can continue the movement with inertia after release.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class ScrollService
Inheritance: objectScrollService
Constructors
Creates a scrolling service for an element and its associated scrollbar.
public ScrollService(RadElement owner, RadScrollBarElement scrollBar)
The element whose pointer state and size are used to process scrolling.
scrollBarRadScrollBarElementThe scrollbar whose orientation, range, and value are updated.
Properties
Gets or sets the coefficient in the quadratic deceleration term of the inertial movement calculation.
public double Deceleration { get; set; }
Gets or sets whether timed movement uses inertia; when disabled, the timer applies proportional scroll steps instead.
public bool EnableInertia { get; set; }
Gets or sets the timer interval, in milliseconds, used for timed scroll updates.
public int Interval { get; set; }
Gets whether the service is tracking a drag or processing timed scroll movement.
public bool IsScrolling { get; }
Gets the element whose pointer and size information is used by this service.
public RadElement Owner { get; }
Gets or sets the multiplier applied when estimating pointer velocity for inertial movement.
public double VelocityFactor { get; set; }
Methods
Stops any current movement and records the starting pointer location for a new drag.
public void MouseDown(Point location)
The pointer location in the coordinate space used by subsequent move events.
Converts a held left-button drag into scroll steps along the associated scrollbar's orientation. Pointer updates received within 40 milliseconds of the previous applied update are buffered; a later eligible drag update applies them, while a non-buffered timer update can discard them.
public void MouseMove(Point point)
The current pointer location in the same coordinate space as the other pointer updates.
Starts timed movement when the last drag update was recent and nonzero; otherwise stops the service.
Stops timed scrolling and clears the current drag delta.
public void Stop()