dom/plugins/test/mochitest/test_pluginstream_asfile.html

changeset 0
6474c204b198
equal deleted inserted replaced
-1:000000000000 0:b5e753e1cfc6
1 <html>
2 <head>
3 <title>NPAPI NP_ASFILE NPStream Test</title>
4 <script type="text/javascript"
5 src="/tests/SimpleTest/SimpleTest.js"></script>
6 <script type="text/javascript"
7 src="pluginstream.js"></script>
8 <script type="text/javascript" src="utils.js"></script>
9 <script type="text/javascript">
10 setTestPluginEnabledState(SpecialPowers.Ci.nsIPluginTag.STATE_ENABLED);
11 </script>
12 <link rel="stylesheet" type="text/css"
13 href="/tests/SimpleTest/test.css" />
14 </head>
15 <body>
16 <p id="display"></p>
17
18 <iframe id="testframe" name="testframe" onload="frameLoaded()"></iframe>
19
20 <!--
21 - Similar to the above tests, but NPP_NewStream sets the stream mode
22 - to NP_ASFILE. In this test, stream data is written in a series of
23 - NPP_Write calls, as per NP_NORMAL, and also written to a file whose
24 - path is passed to NPP_StreamAsFile. The plugin compares the file
25 - and the stream to verify they're indentical, then passes the stream
26 - back to the browser via NPN_GetURL as above.
27 -->
28 <embed src="loremipsum_file.txt" streammode="asfile"
29 frame="testframe"
30 id="embedtest" style="width: 400px; height: 100px;"
31 type="application/x-test"></embed>
32 </body>
33 </html>

mercurial