Skip to content

Commit a800edf

Browse files
authored
Update FocusNode documentation (#126331)
## Description This PR adds some details in FocusNode documentation to explain more precisely when listeners are notified. ## Related Issue Fixes flutter/flutter#126149 ## Tests Documentation only.
1 parent 58454e9 commit a800edf

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/flutter/lib/src/widgets/focus_manager.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,9 @@ enum UnfocusDisposition {
298298
/// [ancestors] and [descendants] accessors.
299299
///
300300
/// [FocusNode]s are [ChangeNotifier]s, so a listener can be registered to
301-
/// receive a notification when the focus changes. If the [Focus] and
301+
/// receive a notification when the focus changes. Listeners will also be
302+
/// notified when [skipTraversal], [canRequestFocus], [descendantsAreFocusable],
303+
/// and [descendantsAreTraversable] properties are updated. If the [Focus] and
302304
/// [FocusScope] widgets are being used to manage the nodes, consider
303305
/// establishing an [InheritedWidget] dependency on them by calling [Focus.of]
304306
/// or [FocusScope.of] instead. [FocusNode.hasFocus] can also be used to

0 commit comments

Comments
 (0)