Parcourir la source

Realank#197 shadowThemeOnly is removed on flutter master and we'd better use InheritedTheme.captureAll (flutter/flutter#69050)

Takashi Kawasaki il y a 5 ans
Parent
commit
7681e20654
1 fichiers modifiés avec 1 ajouts et 5 suppressions
  1. 1 5
      lib/flutter_datetime_picker.dart

+ 1 - 5
lib/flutter_datetime_picker.dart

@@ -212,11 +212,7 @@ class _DatePickerRoute<T> extends PopupRoute<T> {
         pickerModel: pickerModel,
       ),
     );
-    ThemeData inheritTheme = Theme.of(context, shadowThemeOnly: true);
-    if (inheritTheme != null) {
-      bottomSheet = new Theme(data: inheritTheme, child: bottomSheet);
-    }
-    return bottomSheet;
+    return InheritedTheme.captureAll(context, bottomSheet);
   }
 }