Greg Spencer 8ec4c59e55
Fix DropdownMenu throwing TextEditingController disposed error on select (#139385)
## Description

When a DropdownMenu exists within another menu and a MenuItem is selected, the `TextEditingController` of the DropdownMenu is used after it has been disposed.

This PR manages the local `TextController` instance better, making sure that the one used when building is the current one, and handling the case where the `controller` is set on the widget after initial creation.

Also, places where we were setting the text and selection separately were converted to use `TextEditingValue` and set the value atomically.

## Related Issues
 - Fixes https://github.com/flutter/flutter/issues/139266

## Tests
 - Added tests (Created by @josh-burton  in https://github.com/flutter/flutter/pull/139268 - Thanks Josh!)
2023-12-05 01:39:29 +00:00
..
2023-10-27 01:09:03 +00:00
2023-10-31 17:36:10 +00:00
2023-10-31 17:36:10 +00:00
2023-11-27 15:33:07 -08:00
2023-11-07 10:26:23 -08:00
2023-11-21 21:46:07 +00:00
2023-11-07 10:26:23 -08:00