Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Add DOM TouchEvent modifiers accessors #36836

Merged

Conversation

bleroux
Copy link
Contributor

@bleroux bleroux commented Oct 18, 2022

Description

This PR adds modifiers accessors (altKey, ctrlKey, metaKey, shiftKey) to DomTouchEventExtension, as defined in the current W3C specification: https://www.w3.org/TR/touch-events/#attributes-2

Motivation

Those accessors are needed to implement #36724.
See this review comment: #36724 (review).

Related Issue

Fixes flutter/flutter#113605

Tests

Update 3 tests

@flutter-dashboard flutter-dashboard bot added the platform-web Code specifically for the web engine label Oct 18, 2022
@bleroux bleroux changed the title Add DOM TouchEvent modifier accessors Add DOM TouchEvent modifiers accessors Oct 18, 2022
@bleroux bleroux requested a review from dkwingsmt October 18, 2022 14:00
@@ -2571,10 +2610,35 @@ mixin _MultiPointerEventMixin on _BasicEventContext {
}
}

mixin _KeyboardModifiersMixin on _BasicEventContext {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My memory to this file is getting vague, but since this mixin is used for all three event classes, can we just add these new properties to _BasicEventContext?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we just add these new properties to _BasicEventContext?

Done, my first implementation was more complex so I did not want to clutter _BasicEventContent.

@bleroux bleroux requested a review from dkwingsmt October 18, 2022 19:56
Copy link
Contributor

@dkwingsmt dkwingsmt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bleroux bleroux added the autosubmit Merge PR when tree becomes green via auto submit App label Oct 19, 2022
@auto-submit auto-submit bot merged commit f32d290 into flutter:main Oct 19, 2022
@bleroux bleroux deleted the add_dom_touch_event_modifiers-accessors branch October 19, 2022 06:25
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 19, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 20, 2022
zanderso pushed a commit to flutter/flutter that referenced this pull request Oct 20, 2022
…113761)

* 9f09f4ce8 Roll Dart SDK from f21024945abf to 99f266a404bd (1 revision) (flutter/engine#36860)

* 3f58c9743 [Impeller] Polyline generation optimization. (flutter/engine#36759)

* d6ccb2d67 Roll Skia from af544866f04d to 161637433767 (1 revision) (flutter/engine#36861)

* f32d29056 Add DOM TouchEvent modifiers accessors (flutter/engine#36836)

* dd9159958 Roll Fuchsia Linux SDK from oMrS1TjaSIjntnBvR... to IvN-WLezL2sS_wSzZ... (flutter/engine#36862)

* cfe164f66 [fuchsia][scenic] Fix invalid viewRef error in pointer injection. (flutter/engine#36850)

* bd15adf16 Roll Skia from 161637433767 to 50363183d1c7 (3 revisions) (flutter/engine#36864)

* e351b05c7 Roll Fuchsia Mac SDK from XZV0Cqcpiv74L7ric... to M5-c50jCcV0ypwYcT... (flutter/engine#36865)

* a89ed7a72 Roll Skia from 50363183d1c7 to 572d4e85f83e (1 revision) (flutter/engine#36867)

* cca0812cf Roll Skia from 572d4e85f83e to 8928b024556f (1 revision) (flutter/engine#36868)

* 488b76725 Roll Skia from 8928b024556f to 025ae7eec03e (6 revisions) (flutter/engine#36869)

* 7997edc4f [web] Some cleanup for text tests (flutter/engine#36425)

* a831dd269 Roll Skia from 025ae7eec03e to a9255bc938bf (1 revision) (flutter/engine#36870)

* 80847c95f [fuchsia][input] Delete legacy pointer handler (flutter/engine#36857)

* e4c27fc90 Roll Skia from a9255bc938bf to 4fa600316d1d (6 revisions) (flutter/engine#36872)

* 9e635b177 Roll Fuchsia Linux SDK from IvN-WLezL2sS_wSzZ... to zw_jyeiHfJtAXF_qp... (flutter/engine#36875)

* a5c5c25ba Roll Skia from 4fa600316d1d to 723ccd171e37 (3 revisions) (flutter/engine#36876)

* 2f235c4ba Roll Fuchsia Mac SDK from M5-c50jCcV0ypwYcT... to 7lmBrmhOLwrqoqXk0... (flutter/engine#36877)

* 0f0739651 [fuchsia] Bump the Fuchsia target API level to 10 (flutter/engine#36858)

* 490b06d13 Roll Skia from 723ccd171e37 to fc7d5c9ee970 (1 revision) (flutter/engine#36878)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
autosubmit Merge PR when tree becomes green via auto submit App platform-web Code specifically for the web engine
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Web] - Expose DomTouchEvent modifier accessors
2 participants