Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
95e197ba
Unverified
Commit
95e197ba
authored
Aug 30, 2023
by
Polina Cherkasova
Committed by
GitHub
Aug 30, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
_RawAutocompleteState should dispose _highlightedOptionIndex. (#133700)
parent
31600c82
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletion
+4
-1
autocomplete.dart
packages/flutter/lib/src/widgets/autocomplete.dart
+1
-0
autocomplete_test.dart
packages/flutter/test/material/autocomplete_test.dart
+3
-1
No files found.
packages/flutter/lib/src/widgets/autocomplete.dart
View file @
95e197ba
...
...
@@ -565,6 +565,7 @@ class _RawAutocompleteState<T extends Object> extends State<RawAutocomplete<T>>
_floatingOptions
?.
remove
();
_floatingOptions
?.
dispose
();
_floatingOptions
=
null
;
_highlightedOptionIndex
.
dispose
();
super
.
dispose
();
}
...
...
packages/flutter/test/material/autocomplete_test.dart
View file @
95e197ba
...
...
@@ -5,6 +5,7 @@
import
'package:flutter/material.dart'
;
import
'package:flutter/services.dart'
;
import
'package:flutter_test/flutter_test.dart'
;
import
'package:leak_tracker_flutter_testing/leak_tracker_flutter_testing.dart'
;
class
User
{
const
User
({
...
...
@@ -45,7 +46,8 @@ void main() {
User
(
name:
'Charlie'
,
email:
'charlie123@gmail.com'
),
];
testWidgets
(
'can filter and select a list of string options'
,
(
WidgetTester
tester
)
async
{
testWidgetsWithLeakTracking
(
'can filter and select a list of string options'
,
(
WidgetTester
tester
)
async
{
late
String
lastSelection
;
await
tester
.
pumpWidget
(
MaterialApp
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment