RESOLVED FIXED 146853
Add HTMLMediaElement behavior and attribute value restrictions for MediaStream
https://bugs.webkit.org/show_bug.cgi?id=146853
Summary Add HTMLMediaElement behavior and attribute value restrictions for MediaStream
Matthew Daiter
Reported 2015-07-10 13:36:50 PDT
HTMLMediaElement has necessary conditions when running a MediaStream. These conditions must be met to run with standard behavior.
Attachments
Proposed patch. (20.96 KB, patch)
2015-11-02 11:10 PST, Eric Carlson
no flags
Radar WebKit Bug Importer
Comment 1 2015-07-10 13:38:29 PDT
Eric Carlson
Comment 2 2015-11-02 11:10:50 PST
Created attachment 264601 [details] Proposed patch.
Jer Noble
Comment 3 2015-11-02 11:32:33 PST
Comment on attachment 264601 [details] Proposed patch. View in context: https://bugs.webkit.org/attachment.cgi?id=264601&action=review r=me, with the most minor of nits. (Don't feel like you have to change the patch though.) > Source/WebCore/Modules/mediastream/MediaStream.cpp:287 > + bool active = false; > + for (auto& track : m_trackSet.values()) { > + if (!track->ended()) { > + active = true; > + break; > + } > + } It's not really worth it, but you could do: auto& tracks = m_trackSet.values(); bool active = std::any_of(tracks.begin(), tracks.end(), [] (Track* track) { return !track->ended(); }); I wish we had those STL algorithms directly on our storage classes so we could do `m_trackSet.values().any_of([](auto track) { return !track->ended(); });`
WebKit Commit Bot
Comment 4 2015-11-02 13:50:06 PST
Comment on attachment 264601 [details] Proposed patch. Clearing flags on attachment: 264601 Committed r191909: <http://trac.webkit.org/changeset/191909>
WebKit Commit Bot
Comment 5 2015-11-02 13:50:09 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.