image/test/mochitest/test_svg_animatedGIF.html

Wed, 31 Dec 2014 06:55:46 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Wed, 31 Dec 2014 06:55:46 +0100
changeset 1
ca08bd8f51b2
permissions
-rw-r--r--

Added tag TORBROWSER_REPLICA for changeset 6474c204b198

     1 <!DOCTYPE HTML>
     2 <html>
     3 <!--
     4 https://bugzilla.mozilla.org/show_bug.cgi?id=666446
     5 -->
     6 <head>
     7   <title>Test for Bug 666446 - Animated Raster Images inside of SVG Frames</title>
     8   <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/SimpleTest.js"></script>
     9   <script type="application/javascript" src="chrome://mochikit/content/tests/SimpleTest/WindowSnapshot.js"></script>
    10   <script type="application/javascript" src="imgutils.js"></script>
    11   <script type="application/javascript" src="animationPolling.js"></script>
    12   <link rel="stylesheet" type="text/css" href="chrome://mochikit/content/tests/SimpleTest/test.css" />
    13 </head>
    15 <!--  Make sure embed element is snapped to an exact pixel. -->
    16 <div class="bug-header" style="height: 100px;">
    17   <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=666446">
    18   Mozilla Bug 666446: lots of animated gifs swamp us with paint events
    19   </a>
    20 </div>
    22 <p id="display"></p>
    23 <div id="content">
    24   <div id="referenceDiv" style="height: 40px; width: 40px;
    25                                 display: none; background: #2aff00"></div>
    26     <!--
    27         We use <embed> here instead of <img> because the <img> tag utilizes
    28         the VectorImage class for SVG, whereas in this test, we are testing
    29         RasterImage.
    30      -->
    31   <embed id="embeddedSVG" src="animation.svg" type="image/svg+xml" style="display: none;"/>
    32 </div>
    33 <div id="debug" style="display:none"></div>
    34 <pre id="test">
    35 <script type="text/javascript;version=1.8">
    37 /** Test for Bug 666446 nsSVGImageFrame/RasterImage**/
    39 const FAILURE_TIMEOUT = 120000; // Fail early after 120 seconds (2 minutes)
    41 function main() {
    42   var animTest = new AnimationTest(20, FAILURE_TIMEOUT, 'referenceDiv',
    43                                    'embeddedSVG', 'debug', '');
    44   animTest.beginTest();
    45 }
    47 window.onload = main;
    49 </script>
    50 </pre>
    51 </body>
    52 </html>

mercurial