Skip to end of metadata
Go to start of metadata

The UXThumb control can be included in another control, such as a UXSliderBar or UXClock control, to let users change the control's value by dragging the thumb control using mouse device.

UXThumb provides DragStarted, DragCompleted and DragDelta events to manage drag operations associated with the mouse pointer. When user presses the left mouse button, the UXThumb control receives logical focus and mouse capture, and the DragStarted event is raised. While the UXThumb control has focus and mouse capture, the DragDelta event can be raised multiple times without limit. When user releases the left mouse button, the UXThumb control loses mouse capture and the DragCompleted  event is raised.

The event information provides a change in position, but does not reposition the UXThumb. You must manually change or reposition the UXThumb or any other elements that you want to resize or change as a result of the drag operation. The UXThumb control does not provide drag-and-drop functionality.

The following example shows how to use UXThumb to resize a grid container.