This call is unnecessary and wasteful for callers that are building
parallel widget trees, since for those use cases, the caller is
generally going to build the tree synchronously immediately.
This can be useful for offscreen widget trees, where the caller
wants to completely tear down the tree (properly clean up) when
they're done with the tree, to ensure they're not leaving behind
any event listeners that could be registered by child elements
(which could lead to memory leaks and unexpected behavior).
This fixes a subtle bug in the focus traversal that would leave unfocusable FocusTraversalGroup nodes in the list of sorted nodes to be traversed, causing an assert to fire if you nested a FocusTraversalGroup in another one and made its children unfocusable.
This gets away from the extra static map for global key registrations
in favor of the data structures being instance properties of the build
owner. This still allows for semantically-equivalent static access through
the binding (which in turn gives access to the build owner).
This also adds a `BuildOwner.globalKeyCount` getter to get the count
of global keys associated with widgets currently in the tree.
This removes the nullOk parameter from Actions.invoke, and adds an Actions.maybeInvoke function. The difference is that invoke will now always (in debug mode) throw if an enabled action isn't found, and maybeInvoke will return null if an enabled action isn't found. The invoke function can still return null as the result of the invocation, though, so I purposely didn't change the return value to Object from Object?.
This PR replaces the ColoredBox that ListTile uses with an Ink widget. That Ink widget is given a ShapeDecoration with the ListTile's color and shape. This fixes issues where the ListTile color would obscure material ripple effects, and cause the specified shape to not be respected.
List which issues are fixed by this PR. You must list at least one issue.
Fixes#73616Fixes#63877Fixes#67117
If you had to change anything in the flutter/tests repo, include a link to the migration guide as per the breaking change policy.
I modified a handful of tests related to ListTiles. The tests I changed had implementation-specific ways of checking the ListTile color. I have rewritten those so that instead of checking for a ColoredBox with a specific color, they check that a path is painted with the correct color.
I added the following tests to list_tile_test.dart:
"ListTile shows Material ripple effects on top of tileColor" (Regression test for #73616)
"ListTile shape is painted correctly" (Regression test for #63877)
I added the following test to sliver_prototype_item_extent_test.dart:
"SliverPrototypeExtentList prototypeItem paint transform is zero" (Regression test for #67117)
Make RenderCustomPaint consult its preferred size for intrinsics when it has no child. Currently, it returns 0 for its intrinsics, even if it has a non-zero preferred size.
* Making a custom iOS-style text selection menu is now much easier.
* Exposes a new widget for the toolbar, a new widget for the buttons, and a new widget for the layout.
This reverts commit 4901744e62f67ad10440725d2c97e84e66ce77f5, which was a minor breaking change that I missed. Will try to open the PR again following the breaking change process.