Partager via


XRDuration (Windows Embedded CE 6.0)

1/6/2010

This structure defines how long a timeline will play one time.

Syntax

struct XRDuration{
  enum _DurationType{
        DurationType_Automatic,
        DurationType_TimeSpan,
        DurationType_Forever
  };

    XRTimeSpan TimeSpan;
  _DurationType DurationType;
};

Members

  • DurationType
    Indicates the duration type as follows:

    • DurationType_Automatic
      The duration is determined automatically.
    • DurationType_TimeSpan
      The duration is contained in the TimeSpan member.
    • DurationType_Forever
      The duration is infinite. Deprecated.
  • TimeSpan
    An XRTimeSpan value that indicates the duration.

Remarks

You can set XRDuration on a storyboard or animation by using IXRTimeline::SetDuration.

If you use DurationType_Automatic for a storyboard, the timeline continues until the last child animation ends. If you use DurationType_Automatic for an animation, the time span is 1 second. You can use this setting during debugging to verify that the animation starts.

DurationType_Forever is deprecated. A duration of forever results in an animation that never advances from its starting value. If you want an animation to repeat continuously, use IXRTimeline::SetRepeatBehavior.

.NET Framework Equivalent

System.Windows.Duration

Requirements

Header XamlRuntime.h
sysgen SYSGEN_XAML_RUNTIME
Windows Embedded CE Windows Embedded CE 6.0 R3

See Also

Reference

Silverlight for Windows Embedded Structures
IXRTimeline