RESOLVED FIXED 54631
[GTK] media/video-controls-in-media-document.html potentially flaky
https://bugs.webkit.org/show_bug.cgi?id=54631
Summary [GTK] media/video-controls-in-media-document.html potentially flaky
Philippe Normand
Reported 2011-02-17 02:51:46 PST
On GTK the controls could be dumped before the duration becomes known. Rolling the element to play before dumping the tree should fix this issue.
Attachments
proposed patch (4.82 KB, patch)
2011-02-17 02:54 PST, Philippe Normand
no flags
proposed patch (4.80 KB, patch)
2011-02-17 09:18 PST, Philippe Normand
mrobinson: review+
Philippe Normand
Comment 1 2011-02-17 02:54:30 PST
Created attachment 82773 [details] proposed patch
Ami Fischman
Comment 2 2011-02-17 08:33:03 PST
Thanks for doing this! I'm not a webkit reviewer or committer so apparently can't publish in-line comments on the patch; I only had one comment though: View in context: https://bugs.webkit.org/attachment.cgi?id=82773&action=review > LayoutTests/media/video-controls-in-media-document.html:18 > + video.play(); I think you can lose lines 17 & 18 since the mediaDocument specifies autoplay to the generated video tag.
Philippe Normand
Comment 3 2011-02-17 08:55:14 PST
(In reply to comment #2) > Thanks for doing this! > I'm not a webkit reviewer or committer so apparently can't publish in-line comments on the patch; I only had one comment though: > > View in context: https://bugs.webkit.org/attachment.cgi?id=82773&action=review > > > LayoutTests/media/video-controls-in-media-document.html:18 > > + video.play(); > > I think you can lose lines 17 & 18 since the mediaDocument specifies autoplay to the generated video tag. hum doesn't seem to work. Without those 2 lines the test times out here, with the GTK port.
Ami Fischman
Comment 4 2011-02-17 09:05:44 PST
Does the GTK port generally obey the autoplay attribute? Does opening a video file directly in the URL bar of the browser not automatically start playing it? http://trac.webkit.org/browser/trunk/Source/WebCore/html/MediaDocument.cpp#L91 should make it do so.
Philippe Normand
Comment 5 2011-02-17 09:11:06 PST
(In reply to comment #4) > Does the GTK port generally obey the autoplay attribute? yes > Does opening a video file directly in the URL bar of the browser not automatically start playing it? it starts automatically yes. http://trac.webkit.org/browser/trunk/Source/WebCore/html/MediaDocument.cpp#L91 should make it do so. Well yes... I wonder what's happening. Will debug this a bit
Philippe Normand
Comment 6 2011-02-17 09:16:54 PST
It seems the playback starts before the start function is called. Or at least before the event handler is configured. Monitoring timeupdate does the trick :) Will send a new patch
Philippe Normand
Comment 7 2011-02-17 09:18:30 PST
Created attachment 82818 [details] proposed patch
Ami Fischman
Comment 8 2011-02-17 09:37:02 PST
Looks good to me (but I can't set r+ on the patch).
Martin Robinson
Comment 9 2011-02-17 09:43:52 PST
Comment on attachment 82818 [details] proposed patch View in context: https://bugs.webkit.org/attachment.cgi?id=82818&action=review Seems sane to me. Don't forget to rebaseline other platforms once this lands. > LayoutTests/media/video-controls-in-media-document.html:3 > -<script src="media-file.js" type="text/javascript"></script> > +<script src="../http/tests/media/media-file.js" type="text/javascript"></script> Why modify this line?
Anna Cavender
Comment 10 2011-02-17 11:46:10 PST
Yep, you'll need to change the reference to media-file.js as some things have moved around: https://bugs.webkit.org/show_bug.cgi?id=54028
Philippe Normand
Comment 11 2011-02-18 00:30:53 PST
Note You need to log in before you can comment on or make changes to this bug.