dom/smil/test/test_smilCSSPaced.xhtml

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/dom/smil/test/test_smilCSSPaced.xhtml	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,47 @@
     1.4 +<html xmlns="http://www.w3.org/1999/xhtml">
     1.5 +<head>
     1.6 +  <title>Test for Animation Behavior on CSS Properties</title>
     1.7 +  <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
     1.8 +  <script type="text/javascript" src="smilTestUtils.js"></script>
     1.9 +  <script type="text/javascript" src="db_smilCSSPropertyList.js"></script>
    1.10 +  <script type="text/javascript" src="db_smilCSSPaced.js"></script>
    1.11 +  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
    1.12 +</head>
    1.13 +<body>
    1.14 +<p id="display"></p>
    1.15 +<div id="content">
    1.16 +<svg xmlns="http://www.w3.org/2000/svg"
    1.17 +     width="200px" height="200px" font-size="50px" style="color: rgb(50,50,50)"
    1.18 +     onload="this.pauseAnimations()">
    1.19 +  <rect x="20" y="20" width="200" height="200"/>
    1.20 +  <text x="20" y="20">testing 123</text>
    1.21 +  <marker/>
    1.22 +</svg>
    1.23 +</div>
    1.24 +<pre id="test">
    1.25 +<script class="testbody" type="text/javascript">
    1.26 +<![CDATA[
    1.27 +
    1.28 +SimpleTest.waitForExplicitFinish();
    1.29 +
    1.30 +function main()
    1.31 +{
    1.32 +  // Start out with document paused
    1.33 +  var svg = SMILUtil.getSVGRoot();
    1.34 +  ok(svg.animationsPaused(), "should be paused by <svg> load handler");
    1.35 +  is(svg.getCurrentTime(), 0, "should be paused at 0 in <svg> load handler");
    1.36 +
    1.37 +  testBundleList(gPacedBundles, new SMILTimingData(1.0, 6.0));
    1.38 +  // Set "display:none" on everything and run the tests again
    1.39 +  SMILUtil.hideSubtree(SMILUtil.getSVGRoot(), false, false);
    1.40 +  testBundleList(gPacedBundles, new SMILTimingData(1.0, 6.0));
    1.41 +
    1.42 +  SimpleTest.finish();
    1.43 +}
    1.44 +
    1.45 +window.addEventListener("load", main, false);
    1.46 +]]>
    1.47 +</script>
    1.48 +</pre>
    1.49 +</body>
    1.50 +</html>

mercurial