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

Issue 1899653002: Support slotchange event (Closed)

Created:
4 years, 8 months ago by yuzuchan
Modified:
4 years, 8 months ago
Reviewers:
hayato, kochi
CC:
blink-reviews, blink-reviews-dom_chromium.org, blink-reviews-html_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, rwlbuis, sof, webcomponents-bugzilla_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Support slotchange event This CL implements slotchange event, which is added to the microtask queue whenever its assigned nodes or its fallback nodes change. In order to achieve it, this CL separates assignment, distribution and fallback calculations in SlotAssignment. Also note that slotchange event gets fired at most once per a microtask. See the spec issue here: https://github.com/w3c/webcomponents/issues/288 See the spec here: https://dom.spec.whatwg.org/#mutation-algorithms BUG=595287 Committed: https://crrev.com/723a4b536fa9a2f0071c510d14c36918cfee83a9 Cr-Commit-Position: refs/heads/master@{#389056}

Patch Set 1 #

Total comments: 6

Patch Set 2 : Refactor #

Patch Set 3 : Calculate only local assignment #

Patch Set 4 : Add a testcase #

Patch Set 5 : Remove blank #

Patch Set 6 : Fix layout test #

Patch Set 7 : Make the operations more consistent with spec #

Patch Set 8 : Make the operations more consistent with spec #

Patch Set 9 : Remove unnecessary changes #

Patch Set 10 : Remove unnecessary changes #

Patch Set 11 : Refactor #

Total comments: 6

Patch Set 12 : Bug fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+220 lines, -41 lines) Patch
M third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +32 lines, -15 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Element.h View 1 2 3 4 5 6 7 8 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Element.cpp View 1 2 3 4 5 6 7 8 4 chunks +18 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Node.h View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Node.cpp View 1 2 3 4 5 6 7 2 chunks +9 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/dom/shadow/ShadowRoot.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/dom/shadow/ShadowRoot.cpp View 1 2 3 4 5 6 7 8 1 chunk +8 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/dom/shadow/SlotAssignment.h View 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/shadow/SlotAssignment.cpp View 1 2 3 chunks +29 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/html/HTMLSlotElement.h View 1 4 chunks +22 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/html/HTMLSlotElement.cpp View 1 2 3 4 5 6 7 8 9 10 11 15 chunks +95 lines, -16 lines 0 comments Download

Messages

Total messages: 22 (9 generated)
yuzuchan
PTAL :) This is how I feel about this patch: http://i.imgur.com/zGusm9A.gif
4 years, 8 months ago (2016-04-18 04:51:14 UTC) #3
hayato
https://codereview.chromium.org/1899653002/diff/1/third_party/WebKit/Source/core/dom/Element.h File third_party/WebKit/Source/core/dom/Element.h (right): https://codereview.chromium.org/1899653002/diff/1/third_party/WebKit/Source/core/dom/Element.h#newcode874 third_party/WebKit/Source/core/dom/Element.h:874: if (document().shadowCascadeOrder() == ShadowCascadeOrder::ShadowCascadeV1) { Given that CSS is ...
4 years, 8 months ago (2016-04-18 07:16:31 UTC) #4
yuzuchan
PTAL again :) https://codereview.chromium.org/1899653002/diff/1/third_party/WebKit/Source/core/dom/Element.h File third_party/WebKit/Source/core/dom/Element.h (right): https://codereview.chromium.org/1899653002/diff/1/third_party/WebKit/Source/core/dom/Element.h#newcode874 third_party/WebKit/Source/core/dom/Element.h:874: if (document().shadowCascadeOrder() == ShadowCascadeOrder::ShadowCascadeV1) { On ...
4 years, 8 months ago (2016-04-18 09:43:27 UTC) #5
hayato
FYI. I and Anne are updating DOM Standard to define "slotchange" formally. https://github.com/whatwg/dom/pull/229 There, the ...
4 years, 8 months ago (2016-04-19 06:39:34 UTC) #6
yuzuchan
On 2016/04/19 at 06:39:34, hayato wrote: > FYI. I and Anne are updating DOM Standard ...
4 years, 8 months ago (2016-04-21 08:52:03 UTC) #7
yuzuchan
PTAL again :)
4 years, 8 months ago (2016-04-22 02:07:03 UTC) #8
hayato
https://codereview.chromium.org/1899653002/diff/200001/third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html File third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html (right): https://codereview.chromium.org/1899653002/diff/200001/third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html#newcode47 third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html:47: test.done(); Can we remove "test.done()" from d1_s1? I guess ...
4 years, 8 months ago (2016-04-22 05:33:22 UTC) #9
yuzuchan
https://codereview.chromium.org/1899653002/diff/200001/third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html File third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html (right): https://codereview.chromium.org/1899653002/diff/200001/third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html#newcode47 third_party/WebKit/LayoutTests/shadow-dom/slotchange-event.html:47: test.done(); On 2016/04/22 at 05:33:22, hayato wrote: > Can ...
4 years, 8 months ago (2016-04-22 06:59:11 UTC) #10
hayato
LGTM. Could you update the description so that it does not have a long line? ...
4 years, 8 months ago (2016-04-22 07:32:13 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1899653002/220001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1899653002/220001
4 years, 8 months ago (2016-04-22 07:34:39 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1899653002/220001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1899653002/220001
4 years, 8 months ago (2016-04-22 07:35:09 UTC) #18
commit-bot: I haz the power
Committed patchset #12 (id:220001)
4 years, 8 months ago (2016-04-22 08:33:34 UTC) #20
commit-bot: I haz the power
4 years, 8 months ago (2016-04-22 19:45:31 UTC) #22
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/723a4b536fa9a2f0071c510d14c36918cfee83a9
Cr-Commit-Position: refs/heads/master@{#389056}

Powered by Google App Engine
This is Rietveld 408576698