RESOLVED FIXED 83620
Media engine should not be told to prepare for playback if media loading is not allowed
https://bugs.webkit.org/show_bug.cgi?id=83620
Summary Media engine should not be told to prepare for playback if media loading is n...
Eric Carlson
Reported 2012-04-10 14:37:35 PDT
r93437 add a call to prepareToPlay to HTMLMediaElement::load. prepareToPlay tells the media engine to begin buffering data, so it should not be called if media loading requires a user gesture and load() was not called from one.
Attachments
Proposed patch (13.11 KB, patch)
2012-04-12 07:54 PDT, Eric Carlson
mitz: review+
Eric Carlson
Comment 1 2012-04-12 07:54:01 PDT
Created attachment 136912 [details] Proposed patch
Radar WebKit Bug Importer
Comment 2 2012-04-12 12:54:40 PDT
Eric Carlson
Comment 3 2012-04-12 14:19:43 PDT
Min Qin
Comment 4 2012-11-26 14:56:19 PST
Hi, Eric, this change breaks all the youtube embeds on android. For example: http://apiblog.youtube.com/2010/07/new-way-to-embed-youtube-videos.html. And the actual submitted patch is not identical to the proposed patch. I am wondering whether we can either: 1. remove the exception throwing behavior? If an exception is thrown, no video control and no poster will be shown in chrome. And user will see a black square in the middle of a page. Or 2. Use the proposed patch, so that we have the RequireUserGestureForLoadRestriction flag.
Eric Carlson
Comment 5 2012-11-26 15:12:53 PST
(In reply to comment #4) > Hi, Eric, this change breaks all the youtube embeds on android. For example: http://apiblog.youtube.com/2010/07/new-way-to-embed-youtube-videos.html. > > And the actual submitted patch is not identical to the proposed patch. > > I am wondering whether we can either: > 1. remove the exception throwing behavior? If an exception is thrown, no video control and no poster will be shown in chrome. And user will see a black square in the middle of a page. Or > > 2. Use the proposed patch, so that we have the RequireUserGestureForLoadRestriction flag. We should remove the exception because load() is no longer spec'd to throw.
Min Qin
Comment 6 2012-11-26 16:43:52 PST
(In reply to comment #5) > (In reply to comment #4) > > Hi, Eric, this change breaks all the youtube embeds on android. For example: http://apiblog.youtube.com/2010/07/new-way-to-embed-youtube-videos.html. > > > > And the actual submitted patch is not identical to the proposed patch. > > > > I am wondering whether we can either: > > 1. remove the exception throwing behavior? If an exception is thrown, no video control and no poster will be shown in chrome. And user will see a black square in the middle of a page. Or > > > > 2. Use the proposed patch, so that we have the RequireUserGestureForLoadRestriction flag. > > We should remove the exception because load() is no longer spec'd to throw. Thanks, Eric. I created a patch for this: https://bugs.webkit.org/show_bug.cgi?id=103318
Note You need to log in before you can comment on or make changes to this bug.