mirror of
https://github.com/dart-lang/sdk
synced 2024-11-02 08:07:11 +00:00
Fix how composedPath is called
Bug: b/149075352 Event.path should call composedPath if the result of the inline is True. As it is, it only calls it if the result is null, which is erroneous. Change-Id: Idacc9ccddafc4374aca10de84265bf82cfbd0ab9 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/134887 Reviewed-by: Sigmund Cherem <sigmund@google.com>
This commit is contained in:
parent
1554a119ed
commit
8c0d72db1d
3 changed files with 3 additions and 3 deletions
|
@ -14845,7 +14845,7 @@ class Event extends Interceptor {
|
|||
}
|
||||
|
||||
List<EventTarget> get path =>
|
||||
JS('bool', '!!#.composedPath', this) == null ? composedPath() : [];
|
||||
JS<bool>('bool', '!!#.composedPath', this) ? composedPath() : [];
|
||||
|
||||
factory Event._(String type, [Map eventInitDict]) {
|
||||
if (eventInitDict != null) {
|
||||
|
|
|
@ -15413,7 +15413,7 @@ class Event extends Interceptor {
|
|||
}
|
||||
|
||||
List<EventTarget> get path =>
|
||||
JS('bool', '!!#.composedPath', this) == null ? composedPath() : [];
|
||||
JS<bool>('bool', '!!#.composedPath', this) ? composedPath() : [];
|
||||
|
||||
factory Event._(String type, [Map? eventInitDict]) {
|
||||
if (eventInitDict != null) {
|
||||
|
|
|
@ -58,7 +58,7 @@ $(ANNOTATIONS)$(NATIVESPEC)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS
|
|||
}
|
||||
|
||||
List<EventTarget> get path =>
|
||||
JS('bool', '!!#.composedPath', this) == null? composedPath() : [];
|
||||
JS<bool>('bool', '!!#.composedPath', this) ? composedPath() : [];
|
||||
|
||||
$!MEMBERS
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue