diff --git a/lib/main.dart b/lib/main.dart index ad64c06..d3d6bd1 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -220,10 +220,29 @@ class _SplashScreenState extends State { @override Widget build(BuildContext context) { - return new Scaffold( - body: new Center( - child: new Image.asset('assets/images/hyzp_yibin_launche.png'), - // child: new Image.asset('assets/images/hyzp_ybqx_cuipingqu_launche.png'), + // return new Scaffold( + // body: new Center( + // child: new Image.asset('assets/images/hyzp_yibin_launche.png', fit: BoxFit.fill), + // // child: new Image.asset('assets/images/hyzp_ybqx_cuipingqu_launche.png'), + // ), + // ); + // return Container( + // width: MediaQuery.of(context).size.width, // 屏幕宽度 + // height: MediaQuery.of(context).size.height, // 屏幕高度 + // child: Image.asset('assets/images/hyzp_yibin_launche.png', fit: BoxFit.cover), + // ); + //final double statusBarHeight = MediaQuery.of(context).padding.top; + return Scaffold( + body: Column( + children: [ + SizedBox(height: MediaQuery.of(context).padding.top), // 不覆盖顶部状态栏 + Container( + width: MediaQuery.of(context).size.width, // 屏幕宽度 + height: MediaQuery.of(context).size.height - MediaQuery.of(context).padding.top, // 屏幕高度 + child: Image.asset('assets/images/hyzp_yibin_launche.png', fit: BoxFit.cover), + // child: new Image.asset('assets/images/hyzp_ybqx_cuipingqu_launche.png'), + ), + ], ), ); }