Chevrons fade out completely on month picker scroll event (#19422)

This commit is contained in:
Matt Sullivan 2018-07-18 15:44:35 -07:00 committed by GitHub
parent 2af2a08288
commit cf83b790f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -536,9 +536,9 @@ class _MonthPickerState extends State<MonthPicker> with SingleTickerProviderStat
// Setup the fade animation for chevrons // Setup the fade animation for chevrons
_chevronOpacityController = new AnimationController( _chevronOpacityController = new AnimationController(
duration: const Duration(milliseconds: 500), vsync: this duration: const Duration(milliseconds: 250), vsync: this
); );
_chevronOpacityAnimation = new Tween<double>(begin: 1.0, end: 0.5).animate( _chevronOpacityAnimation = new Tween<double>(begin: 1.0, end: 0.0).animate(
new CurvedAnimation( new CurvedAnimation(
parent: _chevronOpacityController, parent: _chevronOpacityController,
curve: Curves.easeInOut, curve: Curves.easeInOut,

View File

@ -671,7 +671,7 @@ void _tests() {
await gesture.moveBy(const Offset(50.0, 100.0)); await gesture.moveBy(const Offset(50.0, 100.0));
await tester.pumpAndSettle(); await tester.pumpAndSettle();
for(RenderAnimatedOpacity renderer in chevronRenderers) { for(RenderAnimatedOpacity renderer in chevronRenderers) {
expect(renderer.opacity.value, equals(0.5)); expect(renderer.opacity.value, equals(0.0));
expect(renderer.opacity.status, equals(AnimationStatus.completed)); expect(renderer.opacity.status, equals(AnimationStatus.completed));
} }