Title: [118363] branches/chromium/1132
- Revision
- 118363
- Author
- [email protected]
- Date
- 2012-05-24 07:03:46 -0700 (Thu, 24 May 2012)
Log Message
Merge 117102 - MediaStream API: Setting onended on a LocalMediaStream triggers an assertion in V8
https://bugs.webkit.org/show_bug.cgi?id=86459
Reviewed by Adam Barth.
Source/WebCore:
LocalMediaStream inherits from MediaStream, but only MediaStream have the
EventTarget idl attribute. Adding the attribute to LocalMediaStream as well fixes the issue.
Test: fast/mediastream/LocalMediaStream-onended.html
* Modules/mediastream/LocalMediaStream.idl:
LayoutTests:
* fast/mediastream/LocalMediaStream-onended-expected.txt: Added.
* fast/mediastream/LocalMediaStream-onended.html: Added.
[email protected]
Review URL: https://chromiumcodereview.appspot.com/10454008
Modified Paths
Added Paths
Diff
Copied: branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended-expected.txt (from rev 117102, trunk/LayoutTests/fast/mediastream/LocalMediaStream-onended-expected.txt) (0 => 118363)
--- branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended-expected.txt (rev 0)
+++ branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended-expected.txt 2012-05-24 14:03:46 UTC (rev 118363)
@@ -0,0 +1,10 @@
+Tests LocalMediaStream::onended callback.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+PASS streamEnded was called.
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Copied: branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended.html (from rev 117102, trunk/LayoutTests/fast/mediastream/LocalMediaStream-onended.html) (0 => 118363)
--- branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended.html (rev 0)
+++ branches/chromium/1132/LayoutTests/fast/mediastream/LocalMediaStream-onended.html 2012-05-24 14:03:46 UTC (rev 118363)
@@ -0,0 +1,50 @@
+<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
+<html>
+<head>
+<link rel="stylesheet" href=""
+<script src=""
+</head>
+<body>
+<p id="description"></p>
+<div id="console"></div>
+<script>
+description("Tests LocalMediaStream::onended callback.");
+
+function error() {
+ testFailed('Stream generation failed.');
+ finishJSTest();
+}
+
+function getUserMedia(dictionary, callback) {
+ try {
+ navigator.webkitGetUserMedia(dictionary, callback, error);
+ } catch (e) {
+ testFailed('webkitGetUserMedia threw exception :' + e);
+ finishJSTest();
+ }
+}
+
+function streamEnded() {
+ testPassed('streamEnded was called.');
+ finishJSTest();
+}
+
+function gotStream(s) {
+ stream = s;
+ try {
+ stream._onended_ = streamEnded;
+ stream.stop();
+ } catch (e) {
+ testFailed('LocalMediaStream threw exception :' + e);
+ finishJSTest();
+ }
+}
+
+getUserMedia({audio:true, video:true}, gotStream);
+
+window.jsTestIsAsync = true;
+window.successfullyParsed = true;
+</script>
+<script src=""
+</body>
+</html>
Modified: branches/chromium/1132/Source/WebCore/Modules/mediastream/LocalMediaStream.idl (118362 => 118363)
--- branches/chromium/1132/Source/WebCore/Modules/mediastream/LocalMediaStream.idl 2012-05-24 13:56:07 UTC (rev 118362)
+++ branches/chromium/1132/Source/WebCore/Modules/mediastream/LocalMediaStream.idl 2012-05-24 14:03:46 UTC (rev 118363)
@@ -26,6 +26,7 @@
interface [
Conditional=MEDIA_STREAM,
+ EventTarget,
JSGenerateToNativeObject,
JSGenerateToJSObject
] LocalMediaStream : MediaStream {
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes