Skip to end of metadata
Go to start of metadata

Remarks

The UXRepeatButton class represents a control that is similar to a UXButton. However, repeat buttons give you control over when and how the Click event occurs. The UXRepeatButton raises the Click event repeatedly from the time it is pressed until it is released. The Delay property determines when the event begins. You can also control the interval of the repetitions with the Interval property.

XAML
C#
The UXRepeatButton is inherited from UXButton, therefore it inherited all characteristic of UXButton including Navigation and Commanding. To learn more about UXButton see UXButton Overview.

Definition

public class UXRepeatButton : UXButton

Summary

The following table summarizes the members exposed in this class.

Public Constructors

UXRepeatButton Constructor()Initializes a new instance of RepeatButton class.

Public Properties

DelayGets or sets the amount of time, in milliseconds, the RepeatButton waits while it is pressed before it starts repeating. The value must be non-negative.
IntervalGets or sets the amount of time, in milliseconds, between repeats once repeating starts. The value must be non-negative.

Fields

DelayPropertyIdentifies the Delay dependency property.
IntervalPropertyIdentifies the Interval dependency property.

Public Methods

AttachEventHandlers()Attach built-in event handlers to control templates. Call this method if necessary.
DetachedEventHandlers()Detach built-in event handlers from control templates. Call this method if necessary.
Dispose()Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
OnApplyTemplate()Build the visual tree for the UXRepeatButton when a new template is applied.

Protected Methods

OnIsEnabledChanged(object, DependencyPropertyChangedEventArgs)Called when the value of IsEnabled property changes.
OnKeyDown(KeyEventArgs)Called before the KeyDown event occurs.
OnKeyUp(KeyEventArgs)Called before the KeyUp event occurs.
OnLostFocus(RoutedEventArgs)Called before the LostFocus event occurs.
OnMouseEnter(MouseEventArgs)Called before the MouseEnter event occurs.
OnMouseLeave(MouseEventArgs)Called before the MouseLeave event occurs.
OnMouseLeftButtonDown(MouseButtonEventArgs)Called before the MouseLeftButtonDown event occurs.
OnMouseLeftButtonUp(MouseButtonEventArgs)Called before the MouseLeftButtonUp event occurs.
OnMouseMove(MouseEventArgs)Called before the MouseMove event occurs.

Public Constructors

public UXRepeatButton()

Initializes a new instance of RepeatButton class.

Public Properties

public int Delay { get; set; }

Gets or sets the amount of time, in milliseconds, the RepeatButton waits while it is pressed before it starts repeating. The value must be non-negative.

public int Interval { get; set; }

Gets or sets the amount of time, in milliseconds, between repeats once repeating starts. The value must be non-negative.

Fields

public static readonly DependencyProperty DelayProperty

Identifies the Delay dependency property.

public static readonly DependencyProperty IntervalProperty

Identifies the Interval dependency property.

Public Methods

public void AttachEventHandlers()

Attach built-in event handlers to control templates. Call this method if necessary.

public void DetachedEventHandlers()

Detach built-in event handlers from control templates. Call this method if necessary.

public void Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void OnApplyTemplate()

Build the visual tree for the UXRepeatButton when a new template is applied.

Protected Methods

protected void OnIsEnabledChanged(object sender, DependencyPropertyChangedEventArgs e)

Called when the value of IsEnabled property changes.

Parameters

senderThe sender of the event.
eThe event data for the property change.

 

protected void OnKeyDown(KeyEventArgs e)

Called before the KeyDown event occurs.

Parameters

eThe data for the event.

 

protected void OnKeyUp(KeyEventArgs e)

Called before the KeyUp event occurs.

Parameters

eThe data for the event.

 

protected void OnLostFocus(RoutedEventArgs e)

Called before the LostFocus event occurs.

Parameters

eThe data for the event.

 

protected void OnMouseEnter(MouseEventArgs e)

Called before the MouseEnter event occurs.

Parameters

eThe data for the event.

 

protected void OnMouseLeave(MouseEventArgs e)

Called before the MouseLeave event occurs.

Parameters

eThe data for the event.

 

protected void OnMouseLeftButtonDown(MouseButtonEventArgs e)

Called before the MouseLeftButtonDown event occurs.

Parameters

eThe data for the event.

 

protected void OnMouseLeftButtonUp(MouseButtonEventArgs e)

Called before the MouseLeftButtonUp event occurs.

Parameters

eThe data for the event.

 

protected void OnMouseMove(MouseEventArgs e)

Called before the MouseMove event occurs.

Parameters

eThe data for the event.
  • No labels