Changeset 57924 in webkit
- Timestamp:
- Apr 20, 2010 3:04:59 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r57922 r57924 1 2010-04-20 Kenneth Rohde Christiansen <kenneth@webkit.org> 2 3 Reviewed by Simon Fraser. 4 5 Rename window.media to window.styleMedia 6 https://bugs.webkit.org/show_bug.cgi?id=36187 7 8 Update layout tests. 9 10 * fast/media/lifetime.html: 11 * fast/media/matchmedium-query-api.html: 12 * fast/media/print-restores-previous-mediatype.html: 13 * fast/media/print-restores-previous-mediatype-expected.txt: 14 1 15 2010-04-20 Justin Schuh <jschuh@chromium.org> 2 16 -
trunk/LayoutTests/fast/media/lifetime.html
r53555 r57924 21 21 function test() 22 22 { 23 if (!window. media) {24 document.getElementById("result").innerHTML = "FAIL - window. media is not supported.";23 if (!window.styleMedia) { 24 document.getElementById("result").innerHTML = "FAIL - window.styleMedia is not supported."; 25 25 return; 26 26 } 27 27 28 media.foo = "bar";28 styleMedia.foo = "bar"; 29 29 gc(); 30 if ( media.foo != "bar") {31 document.getElementById("result").innerHTML = "FAIL - Window.media doesn't return the same object each time.";30 if (styleMedia.foo != "bar") { 31 document.getElementById("result").innerHTML = "FAIL - window.styelMedia doesn't return the same object each time."; 32 32 return; 33 33 } 34 34 35 var m = frames[0]. media;35 var m = frames[0].styleMedia; 36 36 document.body.removeChild(document.getElementsByTagName("iframe")[0]); 37 37 try { m.matchMedium("foobar") } catch (ex) { } -
trunk/LayoutTests/fast/media/matchmedium-query-api.html
r46874 r57924 17 17 function testQuery(query, expected) 18 18 { 19 var isTrue = document.defaultView.media.matchMedium(query);19 var isTrue = window.styleMedia.matchMedium(query); 20 20 21 21 var message = '\"' + query + '\" evaluates to ' + (isTrue ? 'true' : 'false'); -
trunk/LayoutTests/fast/media/print-restores-previous-mediatype-expected.txt
r56209 r57924 1 1 Media type is set to 'handheld' to be different than the default 'screen' 2 PASS: window. media.type should be 'handheld' and is.2 PASS: window.styleMedia.type should be 'handheld' and is. 3 3 4 4 The page is printed, which changes the media type to 'print', and then back 5 PASS: window. media.type should be 'handheld' and is.5 PASS: window.styleMedia.type should be 'handheld' and is. 6 6 -
trunk/LayoutTests/fast/media/print-restores-previous-mediatype.html
r56209 r57924 29 29 { 30 30 log("Media type is set to 'handheld' to be different than the default 'screen'"); 31 shouldBe("window. media.type", window.media.type, "handheld");31 shouldBe("window.styleMedia.type", window.styleMedia.type, "handheld"); 32 32 log("<br>The page is printed, which changes the media type to 'print', and then back"); 33 33 window.print(); 34 shouldBe("window. media.type", window.media.type, "handheld");34 shouldBe("window.styleMedia.type", window.styleMedia.type, "handheld"); 35 35 } 36 36 </script> -
trunk/WebCore/ChangeLog
r57923 r57924 1 2010-04-20 Kenneth Rohde Christiansen <kenneth@webkit.org> 2 3 Reviewed by Simon Fraser. 4 5 Rename window.media to window.styleMedia 6 https://bugs.webkit.org/show_bug.cgi?id=36187 7 8 It has been defined that the AbstractView media extension 9 defined in the CSSOM View spec should be renamed to styleMedia. 10 This patch does that and updates the current layout tests 11 making use of it. 12 13 * page/AbstractView.idl: 14 * page/DOMWindow.cpp: 15 (WebCore::DOMWindow::styleMedia): 16 * page/DOMWindow.h: 17 * page/DOMWindow.idl: 18 1 19 2010-04-20 Timothy Hatcher <timothy@apple.com> 2 20 -
trunk/WebCore/page/AbstractView.idl
r52534 r57924 33 33 ] AbstractView { 34 34 readonly attribute Document document; 35 readonly attribute Media media;35 readonly attribute Media styleMedia; 36 36 }; 37 37 -
trunk/WebCore/page/DOMWindow.cpp
r57865 r57924 1137 1137 } 1138 1138 1139 PassRefPtr<Media> DOMWindow:: media() const1139 PassRefPtr<Media> DOMWindow::styleMedia() const 1140 1140 { 1141 1141 if (!m_media) -
trunk/WebCore/page/DOMWindow.h
r56777 r57924 188 188 Document* document() const; 189 189 // CSSOM View Module 190 PassRefPtr<Media> media() const;190 PassRefPtr<Media> styleMedia() const; 191 191 192 192 // DOM Level 2 Style Interface -
trunk/WebCore/page/DOMWindow.idl
r57205 r57924 142 142 143 143 // CSSOM View Module 144 readonly attribute Media media;144 readonly attribute Media styleMedia; 145 145 146 146 // DOM Level 2 Style Interface
Note: See TracChangeset
for help on using the changeset viewer.