New issue
Advanced search Search tips

Issue 655494 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Oct 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug



Sign in to add a comment

Dispatch synthetic events (at least until its root) when target and relatedTarget are identical

Project Member Reported by hayato@chromium.org, Oct 13 2016

Issue description

Spec: DOM Standard: https://dom.spec.whatwg.org/#dispatching-events 
WPT Update: https://github.com/w3c/web-platform-tests/pull/3865

So far, Blink does not dispatch synthetic events if all of the following conditions are satisfied:
1) event's target is in a shadow tree
2) event has relatedTarget
3) event's target and event's relatedTarget are identical

This does not match the latest DOM Standard.
The new behavior will dispatch synthetic events even if the all conditions are satisfied.

 

Comment 1 by hayato@chromium.org, Oct 13 2016

Status: Started (was: Assigned)
Project Member

Comment 2 by bugdroid1@chromium.org, Oct 13 2016

Comment 3 by hayato@chromium.org, Oct 13 2016

Labels: M-56
Status: Fixed (was: Started)

Comment 4 by tkent@chromium.org, Mar 15 2017

Components: -Blink>DOM>Events Blink>DOM
Remove Blink>DOM>Events
Project Member

Comment 5 by bugdroid1@chromium.org, Jan 19 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9c33d17ab679a084b3c61a00179a95515b061a49

commit 9c33d17ab679a084b3c61a00179a95515b061a49
Author: Hayato Ito <hayato@chromium.org>
Date: Fri Jan 19 02:07:48 2018

Don't dispatch events when target is shadow-including ancestor of relatedTarget

See the discussion at https://github.com/whatwg/dom/pull/336 for details.

Blink implemented it at https://codereview.chromium.org/2384403002, however, it turned out
that both the web platform  test and the implementation were wrong.
This CL fixed the implementation, as well as the web platform test.

Compatibility risk is almost none about this change.

Bug:  655494 
Change-Id: I084cd6b748c304f5f2b395f0b62ba02025385a98
Reviewed-on: https://chromium-review.googlesource.com/869693
Reviewed-by: Takayoshi Kochi <kochi@chromium.org>
Commit-Queue: Hayato Ito <hayato@chromium.org>
Cr-Commit-Position: refs/heads/master@{#530392}
[modify] https://crrev.com/9c33d17ab679a084b3c61a00179a95515b061a49/third_party/WebKit/LayoutTests/external/wpt/shadow-dom/event-composed-path-with-related-target.html
[modify] https://crrev.com/9c33d17ab679a084b3c61a00179a95515b061a49/third_party/WebKit/Source/core/dom/events/EventPath.cpp
[modify] https://crrev.com/9c33d17ab679a084b3c61a00179a95515b061a49/third_party/WebKit/Source/core/dom/events/EventPath.h

Sign in to add a comment