flutter

SizedBox(width: 5), 水平距离5

SizedBox(
  height: 20,
),

Flutter滚动型容器组件 - ListView篇 - 简书

横向滚动效果

flutter纵向滚动嵌套横向滚动_一锅子鱼的博客-CSDN博客_flutter横向滚动

Container 設置邊框,背景顏色,圓角
decoration: new BoxDecoration(
  border: new Border.all(color: AppColors.appbarbackground,width: 1),
  color: AppColors.yiquxiaoColor,
  borderRadius: new BorderRadius.circular((20.0))
borderRadius: BorderRadius.horizontal(left: Radius.circular(10)),//左侧圆角
),

Wbeview 3.0.0 在跳转页面时会出现闪屏问题,2.8.0不会。

上拉加载和下拉刷新:(pub.dev     pull_to_refresh:SmartRefresher)Flutter开发之ListView使用第三方pull_to_refresh加载更多(36) - 灰信网(软件开发博客聚合) (freesion.com)

五:进入页面时左滑右滑的效果

回到上一页面

Navigator.pop(context);   //最简单的返回
Navigator.popAndPushNamed(context, routeName);    //退出当前页面,并添加新的页面 (先删后加)
Navigator.pushNamedAndRemoveUntil( context, newRouteName, (route) => false); //销毁栈内所有页面并跳转
Navigator.pushReplacement(context, newRoute);  //将跳转页替换掉当前页 (先加后删)
Navigator.pushReplacementNamed(context, routeName) 

Navigator.popUntil(context, ModalRoute.withName('/'));

如上代码pop后回到的是登录页,这里‘/’是指回到的根,也就是最初的那一层,所以需要处理一下,在.main 中 加入路由 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值