RESOLVED FIXED Bug 147020
Improve behavior of media elements in page cache.
https://bugs.webkit.org/show_bug.cgi?id=147020
Summary Improve behavior of media elements in page cache.
Andreas Kling
Reported 2015-07-16 14:54:29 PDT
Now that we're caching more pages with media elements, we need to make some improvements to the suspend/resume behavior: 1) Scheduled events should be suspended, not canceled altogether. 2) <source> elements should suspend their error event delivery. 3) When in page cache, network buffering should be turned off. <rdar://problem/21712311>
Attachments
Patch for EWS (5.60 KB, patch)
2015-07-16 16:05 PDT, Andreas Kling
no flags
Patch for EWS (6.17 KB, patch)
2015-07-17 13:42 PDT, Andreas Kling
no flags
Proposed patch (12.76 KB, patch)
2015-07-19 13:33 PDT, Andreas Kling
no flags
Andreas Kling
Comment 1 2015-07-16 16:05:46 PDT
Created attachment 256936 [details] Patch for EWS This patch implements the functionality, but will need tests. Letting EWS have a chew.
Andreas Kling
Comment 2 2015-07-16 16:09:07 PDT
Thought for posterity: Maybe it would be neat to have event queues that automatically respond to page cache suspend/resume without the owner having to worry about it.
Chris Dumez
Comment 3 2015-07-16 16:28:15 PDT
Comment on attachment 256936 [details] Patch for EWS View in context: https://bugs.webkit.org/attachment.cgi?id=256936&action=review > Source/WebCore/html/HTMLSourceElement.cpp:119 > +void HTMLSourceElement::suspendErrorEventDispatch() Maybe we should just mark HTMLSourceElement as an ActiveDOMObject and have it implement suspend() / resume(). Instead of having HTMLMediaElement worry about the source elements when suspending.
Andreas Kling
Comment 4 2015-07-17 13:42:44 PDT
Created attachment 256985 [details] Patch for EWS Again for EWS with HTMLSourceElement now inheriting from ActiveDOMObject.
Andreas Kling
Comment 5 2015-07-19 13:33:25 PDT
Created attachment 257065 [details] Proposed patch
Chris Dumez
Comment 6 2015-07-20 09:32:00 PDT
Comment on attachment 257065 [details] Proposed patch nice, r=me.
WebKit Commit Bot
Comment 7 2015-07-20 13:17:36 PDT
Comment on attachment 257065 [details] Proposed patch Clearing flags on attachment: 257065 Committed r187031: <http://trac.webkit.org/changeset/187031>
WebKit Commit Bot
Comment 8 2015-07-20 13:17:40 PDT
All reviewed patches have been landed. Closing bug.
Michael Catanzaro
Comment 9 2016-06-19 17:09:17 PDT
This broke layout test media/restore-from-page-cache.html for GTK, see bug #158914. Sorry it took a year to be noticed.
Note You need to log in before you can comment on or make changes to this bug.