parentTimeToActiveTime method

Converts a value in the parent timeline to the corresponding point in the element's active timeline.

Syntax

*object.*parentTimeToActiveTime(parentTime)

Parameters

  • parentTime [in]
    Type: double

    An Integer that specifies a point in the parent timeline.

Return value

Type: Integer

An Integer that specifies the point in the active timeline that corresponds to parentTime.

Examples

This example uses the parentTimeToActiveTime method to compare the value of the parent's timeline to the corresponding point in the active timeline. To see the element's point in the active timeline, click the element's parentTimeToActiveTime button.

Code example: http://samples.msdn.microsoft.com/workshop/samples/author/behaviors/parentTimeToActiveTime.htm

<HTML>
<XML:NAMESPACE PREFIX="t"/>
<HEAD>
<TITLE>parentTimeToActiveTime Method</TITLE>
<?IMPORT namespace="t" implementation="#default#time2">

<STYLE>
    .time{behavior: url(#default#time2);}
</STYLE>
</HEAD>

<BODY>

<t:excl id="t1" repeatCount="3">
    <DIV id="div1" class="time" style="color:blue;font-size:1in" begin="1s" 
        dur="5s">Hello World!</DIV>
</t:excl>

<!-- Values allowed for the parent timeline are 1, 2, 3, 4, 5. -->
<!-- This example uses a value of 3. -->
<BR>
<BUTTON onclick="alert('Point in active timeline: ' +
    div1.parentTimeToActiveTime(3));">parentTimeToActiveTime(3)
</BUTTON>

</BODY>
</HTML>

See also

transitionFilter

animate

animateColor

animateMotion

animation

audio

excl

img

media

par

ref

seq

set

time2

video

Reference

activeTime

parentTimeBegin

parentTimeEnd

Conceptual

Introduction to HTML+TIME