Represents accelerating dots moving in a line.
Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class DotsLineWaitingBarIndicatorElement : BaseWaitingBarIndicatorElement, INotifyPropertyChanged, ICustomTypeDescriptor, ISupportSystemSkin, IBindableComponent, IComponent, IDisposable, ISupportDrag, ISupportDrop, IShortcutProvider, IStylableElement, IStylableNode, IPrimitiveElement, IShapedElement, IFillElement, IBorderElement, IBoxStyle, IBoxElement, IDrawFillElement, IImageElement, ITextPrimitive, ITextProvider
Inheritance: objectDisposableObjectRadObjectRadElementVisualElementRadComponentElementRadItemUIItemBaseLightVisualElementBaseWaitingBarIndicatorElementDotsLineWaitingBarIndicatorElement...
Implements:
Inherited Members
Constructors
Creates a right-moving line indicator with dot positions initialized outside the visible track.
public DotsLineWaitingBarIndicatorElement()
Fields
Identifies AccelerationSpeed; the default multiplier is 5.
public static RadProperty AccelerationSpeedProperty
Identifies DelayBetweenAnimationCycles; the default empty-cycle delay is 10 frames.
public static RadProperty DelayBetweenAnimationCyclesProperty
Identifies DistanceBetweenDots; the default gap is 3.
public static RadProperty DistanceBetweenDotsProperty
Identifies DotRadius; the metadata default is 5 before DPI scaling.
public static RadProperty DotRadiusProperty
Identifies SlowSpeedRange; its default value is 42 percent.
public static RadProperty SlowSpeedRangeProperty
Identifies WaitingDirection; the default direction is right.
public static RadProperty WaitingDirectionProperty
Properties
Gets or sets the acceleration speed.
[RadRange(0, 50)]
public double AccelerationSpeed { get; set; }
The acceleration speed.
Gets or sets the empty frames count between animation cycles.
public int DelayBetweenAnimationCycles { get; set; }
The delay between animation cycles.
Gets or sets the distance between dots.
[RadRange(0, 2147483647)]
public double DistanceBetweenDots { get; set; }
The distance between dots.
Gets or sets the dot radius.
[RadRange(0, 2147483647)]
public int DotRadius { get; set; }
The dot radius.
Gets a value indicating whether the WaitingDirection is vertical(Top or Bottom).
public bool IsVertical { get; }
Gets or sets a value, indicating the distance(in percent) which each ball moves with slow speed.
[RadRange(0, 100)]
public int SlowSpeedRange { get; set; }
The slow speed range.
Gets or sets the waiting direction.
public ProgressOrientation WaitingDirection { get; set; }
The waiting direction.
Methods
Advances the dot positions, applying acceleration and the configured pause between completed cycles.
public override void Animate(int step)
The movement increment supplied for this animation frame.
Overrides:
Recalculates the minimum center-to-center spacing from the dot radius and configured gap.
protected virtual void CalculateDotDistances()
Calculates a dot's top-left point according to WaitingDirection and indicates whether it is inside the track.
Creates one initial off-track position for each configured dot.
protected virtual IList<float> CreateDotPositions()
IList<float>
The dot positions used to start a new animation cycle.
Initializes the inter-cycle delay state after the base indicator fields are initialized.
protected override void InitializeFields()
Overrides:
Validates motion-related property changes and restarts the animation when they affect the dot sequence.
protected override void OnPropertyChanged(RadPropertyChangedEventArgs e)
The changed property and its new value.
Overrides:
Draws each currently visible dot using ElementColor.
public void Paint(Graphics graphics, Rectangle rectangle)
The drawing surface.
rectangleRectangleThe bounds passed by the caller; dot placement uses the element's current bounds.
Dot positions are calculated from this element's current bounds rather than the
rectangleargument.
Recalculates dot spacing and restores all dots to their initial off-track positions.
public override void ResetAnimation()
Overrides:
Changes the travel direction and restarts the dot sequence.
public override void UpdateWaitingDirection(ProgressOrientation waitingDirection)
The direction in which the dots travel.
Overrides: