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

Commit 91c8221

Browse files
Adds direction to SemanticsFlag that ensures flutter_test is up to date with the latest flags (#37046)
1 parent 20b4b62 commit 91c8221

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

lib/ui/semantics.dart

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,9 @@ class SemanticsAction {
285285
//
286286
// When changes are made to this class, the equivalent APIs in
287287
// `lib/ui/semantics/semantics_node.h` and in each of the embedders *must* be
288-
// updated.
288+
// updated. If the change affects the visibility of a [SemanticsNode] to
289+
// accessibility services, `flutter_test/controller.dart#SemanticsController._importantFlags`
290+
// must be updated as well.
289291
class SemanticsFlag {
290292
const SemanticsFlag._(this.index) : assert(index != null);
291293

@@ -324,7 +326,10 @@ class SemanticsFlag {
324326
// value in testing/dart/semantics_test.dart, or tests will fail. Also,
325327
// please update the Flag enum in
326328
// flutter/shell/platform/android/io/flutter/view/AccessibilityBridge.java,
327-
// and the SemanticsFlag class in lib/web_ui/lib/semantics.dart.
329+
// and the SemanticsFlag class in lib/web_ui/lib/semantics.dart. If the new flag
330+
// affects the visibility of a [SemanticsNode] to accessibility services,
331+
// `flutter_test/controller.dart#SemanticsController._importantFlags`
332+
// must be updated as well.
328333

329334
/// The semantics node has the quality of either being "checked" or "unchecked".
330335
///

0 commit comments

Comments
 (0)