Title: [106539] trunk
Revision
106539
Author
[email protected]
Date
2012-02-02 00:23:59 -0800 (Thu, 02 Feb 2012)

Log Message

The third argument of addEventListener/removeEventListener of PeerConnection should be optional
https://bugs.webkit.org/show_bug.cgi?id=77606

Reviewed by Adam Barth.

Source/WebCore:

This patch corrects a typo in PeerConnection.idl, i.e. [optional] => [Optional].

Test: fast/mediastream/peerconnection-eventlistener-optional-argument.html

* mediastream/PeerConnection.idl:

LayoutTests:

The added test confirms if the third argument of addEventListener() and
removeEventListener() is optional.

* fast/mediastream/peerconnection-eventlistener-optional-argument-expected.txt: Added.
* fast/mediastream/peerconnection-eventlistener-optional-argument.html: Added.

Modified Paths

Added Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (106538 => 106539)


--- trunk/LayoutTests/ChangeLog	2012-02-02 08:09:07 UTC (rev 106538)
+++ trunk/LayoutTests/ChangeLog	2012-02-02 08:23:59 UTC (rev 106539)
@@ -1,3 +1,16 @@
+2012-02-02  Kentaro Hara  <[email protected]>
+
+        The third argument of addEventListener/removeEventListener of PeerConnection should be optional
+        https://bugs.webkit.org/show_bug.cgi?id=77606
+
+        Reviewed by Adam Barth.
+
+        The added test confirms if the third argument of addEventListener() and
+        removeEventListener() is optional.
+
+        * fast/mediastream/peerconnection-eventlistener-optional-argument-expected.txt: Added.
+        * fast/mediastream/peerconnection-eventlistener-optional-argument.html: Added.
+
 2012-02-01  Philippe Normand  <[email protected]>
 
         [GStreamer] FFTFrame implementation

Added: trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument-expected.txt (0 => 106539)


--- trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument-expected.txt	                        (rev 0)
+++ trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument-expected.txt	2012-02-02 08:23:59 UTC (rev 106539)
@@ -0,0 +1,15 @@
+This test confirms if the third argument of addEventListener() and removeEventListener() is optional.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS pc.addEventListener("foo", function() {}) is undefined
+PASS pc.addEventListener("foo", function() {}, false) is undefined
+PASS pc.addEventListener("foo", function() {}, true) is undefined
+PASS pc.removeEventListener("foo", function() {}) is undefined
+PASS pc.removeEventListener("foo", function() {}, false) is undefined
+PASS pc.removeEventListener("foo", function() {}, true) is undefined
+PASS successfullyParsed is true
+
+TEST COMPLETE
+

Added: trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument.html (0 => 106539)


--- trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument.html	                        (rev 0)
+++ trunk/LayoutTests/fast/mediastream/peerconnection-eventlistener-optional-argument.html	2012-02-02 08:23:59 UTC (rev 106539)
@@ -0,0 +1,25 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<script src=""
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+</body>
+<script>
+description("This test confirms if the third argument of addEventListener() and removeEventListener() is optional.");
+
+var pc = new webkitPeerConnection("some.server.com", function() {});
+shouldBe('pc.addEventListener("foo", function() {})', 'undefined');
+shouldBe('pc.addEventListener("foo", function() {}, false)', 'undefined');
+shouldBe('pc.addEventListener("foo", function() {}, true)', 'undefined');
+shouldBe('pc.removeEventListener("foo", function() {})', 'undefined');
+shouldBe('pc.removeEventListener("foo", function() {}, false)', 'undefined');
+shouldBe('pc.removeEventListener("foo", function() {}, true)', 'undefined');
+
+window.successfullyParsed = true;
+
+</script>
+<script src=""
+</html>

Modified: trunk/Source/WebCore/ChangeLog (106538 => 106539)


--- trunk/Source/WebCore/ChangeLog	2012-02-02 08:09:07 UTC (rev 106538)
+++ trunk/Source/WebCore/ChangeLog	2012-02-02 08:23:59 UTC (rev 106539)
@@ -1,3 +1,16 @@
+2012-02-02  Kentaro Hara  <[email protected]>
+
+        The third argument of addEventListener/removeEventListener of PeerConnection should be optional
+        https://bugs.webkit.org/show_bug.cgi?id=77606
+
+        Reviewed by Adam Barth.
+
+        This patch corrects a typo in PeerConnection.idl, i.e. [optional] => [Optional].
+
+        Test: fast/mediastream/peerconnection-eventlistener-optional-argument.html
+
+        * mediastream/PeerConnection.idl:
+
 2012-02-02  Rakesh KN  <[email protected]>
 
         hidden attribute on <input type=file /> suppresses the file selection dialog

Modified: trunk/Source/WebCore/mediastream/PeerConnection.idl (106538 => 106539)


--- trunk/Source/WebCore/mediastream/PeerConnection.idl	2012-02-02 08:09:07 UTC (rev 106538)
+++ trunk/Source/WebCore/mediastream/PeerConnection.idl	2012-02-02 08:23:59 UTC (rev 106539)
@@ -64,10 +64,10 @@
         // EventTarget interface
         void addEventListener(in DOMString type,
                               in EventListener listener,
-                              in [optional] boolean useCapture);
+                              in [Optional] boolean useCapture);
         void removeEventListener(in DOMString type,
                                  in EventListener listener,
-                                 in [optional] boolean useCapture);
+                                 in [Optional] boolean useCapture);
         boolean dispatchEvent(in Event event)
             raises(EventException);
     };
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to