Fix not-disposed _InputBorderGap. (#132694)
Fixes: https://github.com/flutter/flutter/issues/132620
This commit is contained in:
parent
223ae5d3ac
commit
0ea523cf93
@ -1956,6 +1956,7 @@ class _InputDecoratorState extends State<InputDecorator> with TickerProviderStat
|
|||||||
void dispose() {
|
void dispose() {
|
||||||
_floatingLabelController.dispose();
|
_floatingLabelController.dispose();
|
||||||
_shakingLabelController.dispose();
|
_shakingLabelController.dispose();
|
||||||
|
_borderGap.dispose();
|
||||||
super.dispose();
|
super.dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -243,6 +243,7 @@ void main() {
|
|||||||
expect(controller.text, ' blah2blah1');
|
expect(controller.text, ' blah2blah1');
|
||||||
expect(controller.selection, const TextSelection(baseOffset: 0, extentOffset: 0));
|
expect(controller.selection, const TextSelection(baseOffset: 0, extentOffset: 0));
|
||||||
expect(find.byType(CupertinoButton), findsNothing);
|
expect(find.byType(CupertinoButton), findsNothing);
|
||||||
|
controller.dispose();
|
||||||
},
|
},
|
||||||
variant: const TargetPlatformVariant(<TargetPlatform>{ TargetPlatform.linux, TargetPlatform.windows }),
|
variant: const TargetPlatformVariant(<TargetPlatform>{ TargetPlatform.linux, TargetPlatform.windows }),
|
||||||
skip: kIsWeb, // [intended] we don't supply the cut/copy/paste buttons on the web.
|
skip: kIsWeb, // [intended] we don't supply the cut/copy/paste buttons on the web.
|
||||||
@ -278,11 +279,6 @@ void main() {
|
|||||||
controller.dispose();
|
controller.dispose();
|
||||||
},
|
},
|
||||||
skip: kIsWeb, // [intended] we don't supply the cut/copy/paste buttons on the web.
|
skip: kIsWeb, // [intended] we don't supply the cut/copy/paste buttons on the web.
|
||||||
// TODO(polina-c): remove after fixing
|
|
||||||
// https://github.com/flutter/flutter/issues/132620
|
|
||||||
leakTrackingTestConfig: const LeakTrackingTestConfig(
|
|
||||||
notDisposedAllowList: <String, int?>{'_InputBorderGap' : 1},
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
|
|
||||||
testWidgets('the desktop cut/copy/paste buttons are disabled for read-only obscured form fields', (WidgetTester tester) async {
|
testWidgets('the desktop cut/copy/paste buttons are disabled for read-only obscured form fields', (WidgetTester tester) async {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user