Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(88)

Issue 2657723002: [Blink, Media] Added controlsList to HTMLMediaElement (Closed)

Created:
3 years, 11 months ago by whywhat
Modified:
3 years, 9 months ago
CC:
blink-reviews, blink-reviews-html_chromium.org, chromium-reviews, dglazkov+blink, eric.carlson_apple.com, feature-media-reviews_chromium.org, fs, gasubic, mlamouri+watch-blink_chromium.org, nessy, Srirama, vcarbune.chromium
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Blink, Media] Added controlsList to HTMLMediaElement Adds a DOMTokenList backed controlsList/controlslist attribute to HTMLMediaElement with three keywords: nodownload, nofullscreen and noremoteplayback. Spec change is discussed here: https://github.com/whatwg/html/issues/2293 Spec change PR is here: https://github.com/whatwg/html/pull/2426 WICG repo for the API is here: https://github.com/WICG/controls-list Intent to ship is here: https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/tFuQd3AcsIQ/discussion BUG=650174, 685018 TEST=manual+layout tests Review-Url: https://codereview.chromium.org/2657723002 Cr-Commit-Position: refs/heads/master@{#455926} Committed: https://chromium.googlesource.com/chromium/src/+/caca06866f37c79df89cab9a634bb7497177236e

Patch Set 1 #

Total comments: 8

Patch Set 2 : rebased #

Total comments: 5

Patch Set 3 : Addressed minor comments #

Patch Set 4 : Added layout tests #

Total comments: 6

Patch Set 5 : s/controls/controlslist #

Patch Set 6 : Updated interface expectations #

Patch Set 7 : Moved the layout tests to controls/ #

Patch Set 8 : Rebased and readded the tests #

Total comments: 8

Patch Set 9 : Fixed comments #

Total comments: 6

Patch Set 10 : Addressed nits #

Total comments: 2

Patch Set 11 : Encapsulated the keywords #

Total comments: 1

Patch Set 12 : Added a link to the spec. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+268 lines, -2 lines) Patch
A third_party/WebKit/LayoutTests/http/tests/media/controls/controls-list-add-hide.html View 1 2 3 4 5 6 7 1 chunk +32 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/media/controls/controls-list-remove-show.html View 1 2 3 4 5 6 7 1 chunk +34 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/media/media-controls.js View 1 2 3 1 chunk +16 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/platform/mac/virtual/stable/webexposed/global-interface-listing-expected.txt View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/platform/win/virtual/stable/webexposed/global-interface-listing-expected.txt View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/virtual/stable/webexposed/element-instance-property-listing-expected.txt View 1 2 3 4 5 6 7 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/webexposed/element-instance-property-listing-expected.txt View 1 2 3 4 5 6 7 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt View 1 2 3 4 5 6 7 8 9 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/frame/UseCounter.h View 1 2 3 4 5 6 7 8 9 1 chunk +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/BUILD.gn View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/HTMLAttributeNames.json5 View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/HTMLMediaElement.h View 1 2 3 4 5 6 7 8 9 10 5 chunks +5 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/html/HTMLMediaElement.cpp View 1 2 3 4 5 6 7 8 9 10 4 chunks +24 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/html/HTMLMediaElement.idl View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -0 lines 0 comments Download
A third_party/WebKit/Source/core/html/HTMLMediaElementControlsList.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +45 lines, -0 lines 0 comments Download
A third_party/WebKit/Source/core/html/HTMLMediaElementControlsList.cpp View 1 2 3 4 5 6 7 8 9 10 1 chunk +60 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp View 1 2 3 4 5 6 7 8 9 10 2 chunks +8 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/shadow/MediaControls.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/html/shadow/MediaControls.cpp View 1 2 3 4 5 6 7 8 9 10 4 chunks +20 lines, -0 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 3 4 5 6 7 8 9 10 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 79 (45 generated)
whywhat
Mounir for the initial review
3 years, 11 months ago (2017-01-25 02:02:52 UTC) #2
mlamouri (slow - plz ping)
Looks generally good but this will require some tests :) https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/BUILD.gn File third_party/WebKit/Source/core/html/BUILD.gn (right): https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/BUILD.gn#newcode112 ...
3 years, 11 months ago (2017-01-25 05:27:32 UTC) #7
fs
Drive-by (on attribute handling) https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp File third_party/WebKit/Source/core/html/HTMLMediaElement.cpp (right): https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp#newcode568 third_party/WebKit/Source/core/html/HTMLMediaElement.cpp:568: m_controlsList->setValue(fastGetAttribute(controlsAttr)); m_controlsList->setValue(params.newValue); (and params.oldValue != ...
3 years, 11 months ago (2017-01-25 09:34:16 UTC) #8
whywhat
rebased
3 years, 9 months ago (2017-03-01 14:43:56 UTC) #9
whywhat
Addressed minor comments
3 years, 9 months ago (2017-03-01 16:14:33 UTC) #10
whywhat
https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/BUILD.gn File third_party/WebKit/Source/core/html/BUILD.gn (right): https://codereview.chromium.org/2657723002/diff/1/third_party/WebKit/Source/core/html/BUILD.gn#newcode112 third_party/WebKit/Source/core/html/BUILD.gn:112: "HTMLMediaElementControlsList.cpp", On 2017/01/25 at 05:27:31, mlamouri wrote: > You ...
3 years, 9 months ago (2017-03-01 16:17:20 UTC) #11
mlamouri (slow - plz ping)
sg but it's missing tests :) https://codereview.chromium.org/2657723002/diff/20001/third_party/WebKit/Source/core/html/HTMLMediaElement.idl File third_party/WebKit/Source/core/html/HTMLMediaElement.idl (right): https://codereview.chromium.org/2657723002/diff/20001/third_party/WebKit/Source/core/html/HTMLMediaElement.idl#newcode79 third_party/WebKit/Source/core/html/HTMLMediaElement.idl:79: [CEReactions, SameObject, PutForwards=value] ...
3 years, 9 months ago (2017-03-01 16:20:21 UTC) #12
whywhat
Added layout tests
3 years, 9 months ago (2017-03-02 20:42:47 UTC) #13
mlamouri (slow - plz ping)
sgtm but it needs to be updated to match the latest proposal I guess https://codereview.chromium.org/2657723002/diff/60001/third_party/WebKit/LayoutTests/http/tests/media/controls-list-add-hide.html ...
3 years, 9 months ago (2017-03-03 10:38:41 UTC) #18
whywhat
s/controls/controlslist
3 years, 9 months ago (2017-03-03 15:41:06 UTC) #19
whywhat
Updated interface expectations
3 years, 9 months ago (2017-03-03 15:53:58 UTC) #20
whywhat
Moved the layout tests to controls/
3 years, 9 months ago (2017-03-03 16:02:31 UTC) #21
whywhat
PTAL https://codereview.chromium.org/2657723002/diff/60001/third_party/WebKit/LayoutTests/http/tests/media/controls-list-add-hide.html File third_party/WebKit/LayoutTests/http/tests/media/controls-list-add-hide.html (right): https://codereview.chromium.org/2657723002/diff/60001/third_party/WebKit/LayoutTests/http/tests/media/controls-list-add-hide.html#newcode2 third_party/WebKit/LayoutTests/http/tests/media/controls-list-add-hide.html:2: <title>Test adding keywords to controlsList hides buttons</title> On ...
3 years, 9 months ago (2017-03-03 16:04:55 UTC) #22
whywhat
Rebased and readded the tests
3 years, 9 months ago (2017-03-03 16:19:50 UTC) #27
mlamouri (slow - plz ping)
https://codereview.chromium.org/2657723002/diff/140001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp File third_party/WebKit/Source/core/html/HTMLMediaElement.cpp (right): https://codereview.chromium.org/2657723002/diff/140001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp#newcode2456 third_party/WebKit/Source/core/html/HTMLMediaElement.cpp:2456: updateControlsVisibility(); What about calling: ``` if (mediaControls()) mediaControls->reset(); ``` ...
3 years, 9 months ago (2017-03-03 17:32:44 UTC) #30
whywhat
Fixed comments
3 years, 9 months ago (2017-03-07 12:58:56 UTC) #33
whywhat
UseCounters is a pain to rebase -- I imagine it's a pain to merge too ...
3 years, 9 months ago (2017-03-07 12:59:46 UTC) #34
jochen (gone - plz use gerrit)
can you add a link to the intent to ship to the CL description please?
3 years, 9 months ago (2017-03-09 16:09:59 UTC) #41
whywhat
On 2017/03/09 at 16:09:59, jochen wrote: > can you add a link to the intent ...
3 years, 9 months ago (2017-03-09 16:13:28 UTC) #43
mlamouri (slow - plz ping)
lgtm with comments applied \o/ https://codereview.chromium.org/2657723002/diff/160001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp File third_party/WebKit/Source/core/html/HTMLMediaElement.cpp (right): https://codereview.chromium.org/2657723002/diff/160001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp#newcode607 third_party/WebKit/Source/core/html/HTMLMediaElement.cpp:607: updateControlsVisibility(); should this be: ...
3 years, 9 months ago (2017-03-09 16:45:45 UTC) #45
whywhat
Addressed nits
3 years, 9 months ago (2017-03-09 16:58:43 UTC) #46
whywhat
https://codereview.chromium.org/2657723002/diff/160001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp File third_party/WebKit/Source/core/html/HTMLMediaElement.cpp (right): https://codereview.chromium.org/2657723002/diff/160001/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp#newcode607 third_party/WebKit/Source/core/html/HTMLMediaElement.cpp:607: updateControlsVisibility(); On 2017/03/09 at 16:45:45, mlamouri wrote: > should ...
3 years, 9 months ago (2017-03-09 16:59:43 UTC) #47
DaleCurtis
https://codereview.chromium.org/2657723002/diff/180001/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp File third_party/WebKit/Source/core/html/shadow/MediaControls.cpp (right): https://codereview.chromium.org/2657723002/diff/180001/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp#newcode71 third_party/WebKit/Source/core/html/shadow/MediaControls.cpp:71: if (mediaElement.controlsList()->tokens().contains("nofullscreen")) { Do you really want callers to ...
3 years, 9 months ago (2017-03-09 18:45:49 UTC) #53
whywhat
Encapsulated the keywords
3 years, 9 months ago (2017-03-09 19:55:10 UTC) #54
whywhat
Thanks for the drive-by! https://codereview.chromium.org/2657723002/diff/180001/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp File third_party/WebKit/Source/core/html/shadow/MediaControls.cpp (right): https://codereview.chromium.org/2657723002/diff/180001/third_party/WebKit/Source/core/html/shadow/MediaControls.cpp#newcode71 third_party/WebKit/Source/core/html/shadow/MediaControls.cpp:71: if (mediaElement.controlsList()->tokens().contains("nofullscreen")) { On 2017/03/09 ...
3 years, 9 months ago (2017-03-09 19:56:45 UTC) #55
Rick Byers
virtual/webexposed LGTM https://codereview.chromium.org/2657723002/diff/200001/third_party/WebKit/Source/core/html/HTMLMediaElement.idl File third_party/WebKit/Source/core/html/HTMLMediaElement.idl (right): https://codereview.chromium.org/2657723002/diff/200001/third_party/WebKit/Source/core/html/HTMLMediaElement.idl#newcode79 third_party/WebKit/Source/core/html/HTMLMediaElement.idl:79: [SameObject, PutForwards=value] readonly attribute DOMTokenList controlsList; nit ...
3 years, 9 months ago (2017-03-09 20:00:58 UTC) #59
whywhat
Added a link to the spec.
3 years, 9 months ago (2017-03-09 20:05:20 UTC) #61
DaleCurtis
Cool, non-owner lgtm!
3 years, 9 months ago (2017-03-09 20:05:35 UTC) #62
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/382242)
3 years, 9 months ago (2017-03-09 20:40:48 UTC) #69
whywhat
+jwd for histograms.xml changes
3 years, 9 months ago (2017-03-09 20:43:35 UTC) #71
whywhat
+haraken
3 years, 9 months ago (2017-03-09 20:49:34 UTC) #73
haraken
histograms.xml LGTM
3 years, 9 months ago (2017-03-09 21:51:16 UTC) #74
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2657723002/220001
3 years, 9 months ago (2017-03-09 21:55:36 UTC) #76
commit-bot: I haz the power
3 years, 9 months ago (2017-03-10 00:40:46 UTC) #79
Message was sent while issue was closed.
Committed patchset #12 (id:220001) as
https://chromium.googlesource.com/chromium/src/+/caca06866f37c79df89cab9a634b...

Powered by Google App Engine
This is Rietveld 408576698