pageView默認是可以左右滑動的,如果想禁止滑動加上這個參數就可以
physics: NeverScrollableScrollPhysics()
PageView(
physics: NeverScrollableScrollPhysics(), //禁止滑動
controller: _controller,
children: <Widget>[Page1(), Page2(), Page3()],
),
pageView默認是可以左右滑動的,如果想禁止滑動加上這個參數就可以
physics: NeverScrollableScrollPhysics()
PageView(
physics: NeverScrollableScrollPhysics(), //禁止滑動
controller: _controller,
children: <Widget>[Page1(), Page2(), Page3()],
),