Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / media / mq-js-stylesheet-media-04.html
blob4464f201ddf4342f6f3d7de0287ccddd58356593
1 <html>
2 <head>
3 <title>CSS3 media query test: stylesheet media deleteMedium </title>
4 <link rel="help" href="http://www.w3.org/TR/css3-mediaqueries/" />
5 <link rel="help" href="http://www.w3.org/TR/DOM-Level-2-Style/stylesheets.html" />
6 <style type="text/css" media="braille, not screen">
7 p { color: green }
8 </style>
10 <script language="javascript">
11 function test() {
12 var re = document.getElementById("result");
13 var media = document.styleSheets[0].media;
14 media.appendMedium("screen and (color)");
15 while (media.length) {
16 media.deleteMedium(media.item(0));
18 re.innerHTML = "media list is empty"
19 var first = true;
20 for (var i = 0; i < media.length; ++i) {
21 if (!first) re.innerHTML += ", " + media.item(i);
22 else re.innerHTML = media.item(i);
23 first = false;
26 </script>
28 </head>
29 <body onload="test()">
30 <!-- FIXME: NOTE! This will fail until dynamic setting of media property causes style recalculation.
31 This is not the case currently (24.07.2005)
32 -->
33 <p> This text should be green and below should read "media list is empty". </p>
34 <p id="result">Failure: test not run</p>
35 <p> Expected to fail (24.7.2005) </p>
36 </body>
37 </html>