Explorar o código

Merge pull request #184 from maerlynflagg/maerlynflagg-patch-1

Enabling UI refresh on change the right list
刘彦博 %!s(int64=4) %!d(string=hai) anos
pai
achega
63871e1473
Modificáronse 1 ficheiros con 6 adicións e 2 borrados
  1. 6 2
      lib/flutter_datetime_picker.dart

+ 6 - 2
lib/flutter_datetime_picker.dart

@@ -412,8 +412,12 @@ class _DatePickerState extends State<_DatePickerComponent> {
                     rightScrollCtrl,
                     widget.pickerModel.layoutProportions()[2], (index) {
                     widget.pickerModel.setRightIndex(index);
-                    _notifyDateChanged();
-                  }, null)
+                  }, (index) {
+                    setState(() {
+                      refreshScrollOffset();
+                      _notifyDateChanged();
+                    });
+                  })
                 : null,
           ),
         ],