[chromium] compositing tests with videos fail in chromium DumpRenderTree, seeking...
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 18:21:16 +0000 (18:21 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 16 Mar 2012 18:21:16 +0000 (18:21 +0000)
https://bugs.webkit.org/show_bug.cgi?id=76511

Patch by Aaron Colwell <acolwell@chromium.org> on 2012-03-16
Reviewed by Eric Carlson.

* compositing/resources/media-testing.js:
(ensureFrameVisible.playingHandler):
(ensureFrameVisible.seekedHandler):
(ensureFrameVisible):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@111029 268f45cc-cd09-0410-ab3c-d52691b4dbfc

LayoutTests/ChangeLog
LayoutTests/compositing/resources/media-testing.js

index ae8a434502064472ee6b7492d6a0cc3e74ac358c..907412bee45db68b5a4e37af14c6a2998e81b974 100644 (file)
@@ -1,3 +1,15 @@
+2012-03-16  Aaron Colwell  <acolwell@chromium.org>
+
+        [chromium] compositing tests with videos fail in chromium DumpRenderTree, seeking doesn't appear to work
+        https://bugs.webkit.org/show_bug.cgi?id=76511
+
+        Reviewed by Eric Carlson.
+
+        * compositing/resources/media-testing.js:
+        (ensureFrameVisible.playingHandler):
+        (ensureFrameVisible.seekedHandler):
+        (ensureFrameVisible):
+
 2012-03-08  Jer Noble  <jer.noble@apple.com>
 
         Support W3C Full Screen API proposal
index e303778d9f8dda4ead08be7eff038a3a8a121eba..0da79e7aa36257040531b736f7211b14d1fb961c 100644 (file)
@@ -4,13 +4,18 @@ if (window.layoutTestController)
 
 function ensureFrameVisible(video, videoRenderedCallback)
 {
-    video.addEventListener('timeupdate', function() {
+    var playingHandler = function() {
         video.pause();
         video.currentTime = 0;
+    };
+
+    var seekedHandler = function() {
         if (videoRenderedCallback)
             videoRenderedCallback();
-    }, false);
-    
+    };
+
+    video.addEventListener('playing', playingHandler, false);
+    video.addEventListener('seeked', seekedHandler, false);
     video.play();
 }