@@ -279,6 +279,7 @@ class SemanticsFlag {
279
279
static const int _kIsLiveRegionIndex = 1 << 15 ;
280
280
static const int _kHasToggledStateIndex = 1 << 16 ;
281
281
static const int _kIsToggledIndex = 1 << 17 ;
282
+ static const int _kHasImplicitScrollingIndex = 1 << 18 ;
282
283
283
284
const SemanticsFlag ._(this .index);
284
285
@@ -465,6 +466,15 @@ class SemanticsFlag {
465
466
/// * [SemanticsFlag.hasToggledState] , which enables a toggled state.
466
467
static const SemanticsFlag isToggled = const SemanticsFlag ._(_kIsToggledIndex);
467
468
469
+ /// Whether the platform can scroll the semantics node when the user attempts
470
+ /// to move focus to an offscreen child.
471
+ ///
472
+ /// For example, a [ListView] widget has implicit scrolling so that users can
473
+ /// easily move to the next visible set of children. A [TabBar] widget does
474
+ /// not have implicit scrolling, so that users can navigate into the tab
475
+ /// body when reaching the end of the tab bar.
476
+ static const SemanticsFlag hasImplicitScrolling = const SemanticsFlag ._(_kHasImplicitScrollingIndex);
477
+
468
478
/// The possible semantics flags.
469
479
///
470
480
/// The map's key is the [index] of the flag and the value is the flag itself.
@@ -487,6 +497,7 @@ class SemanticsFlag {
487
497
_kIsLiveRegionIndex: isLiveRegion,
488
498
_kHasToggledStateIndex: hasToggledState,
489
499
_kIsToggledIndex: isToggled,
500
+ _kHasImplicitScrollingIndex: hasImplicitScrolling,
490
501
};
491
502
492
503
@override
@@ -528,6 +539,8 @@ class SemanticsFlag {
528
539
return 'SemanticsFlag.hasToggledState' ;
529
540
case _kIsToggledIndex:
530
541
return 'SemanticsFlag.isToggled' ;
542
+ case _kHasImplicitScrollingIndex:
543
+ return 'SemanticsFlag.hasImplicitScrolling' ;
531
544
}
532
545
return null ;
533
546
}
0 commit comments