Fix backdrop demo margin for iPhone X (#17480)

This commit is contained in:
xster
2018-05-10 17:36:20 -07:00
committed by GitHub
parent e42c50cf20
commit e8d99d12c4

View File

@@ -315,7 +315,12 @@ class _BackdropDemoState extends State<BackdropDemo> with SingleTickerProviderSt
final double panelTop = panelSize.height - panelTitleHeight;
final Animation<RelativeRect> panelAnimation = new RelativeRectTween(
begin: new RelativeRect.fromLTRB(0.0, panelTop, 0.0, panelTop - panelSize.height),
begin: new RelativeRect.fromLTRB(
0.0,
panelTop - MediaQuery.of(context).padding.bottom,
0.0,
panelTop - panelSize.height,
),
end: const RelativeRect.fromLTRB(0.0, 0.0, 0.0, 0.0),
).animate(
new CurvedAnimation(