From a800edfff9f54c7bf8aac3f80c4706ff34d19b6e Mon Sep 17 00:00:00 2001 From: Bruno Leroux Date: Tue, 9 May 2023 17:50:51 +0200 Subject: [PATCH] Update FocusNode documentation (#126331) ## Description This PR adds some details in FocusNode documentation to explain more precisely when listeners are notified. ## Related Issue Fixes https://github.com/flutter/flutter/issues/126149 ## Tests Documentation only. --- packages/flutter/lib/src/widgets/focus_manager.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/flutter/lib/src/widgets/focus_manager.dart b/packages/flutter/lib/src/widgets/focus_manager.dart index 8d9df31093..b167ed114d 100644 --- a/packages/flutter/lib/src/widgets/focus_manager.dart +++ b/packages/flutter/lib/src/widgets/focus_manager.dart @@ -298,7 +298,9 @@ enum UnfocusDisposition { /// [ancestors] and [descendants] accessors. /// /// [FocusNode]s are [ChangeNotifier]s, so a listener can be registered to -/// receive a notification when the focus changes. If the [Focus] and +/// receive a notification when the focus changes. Listeners will also be +/// notified when [skipTraversal], [canRequestFocus], [descendantsAreFocusable], +/// and [descendantsAreTraversable] properties are updated. If the [Focus] and /// [FocusScope] widgets are being used to manage the nodes, consider /// establishing an [InheritedWidget] dependency on them by calling [Focus.of] /// or [FocusScope.of] instead. [FocusNode.hasFocus] can also be used to