You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.3 KiB
47 lines
1.3 KiB
3 years ago
|
import 'package:flutter/material.dart';
|
||
|
import 'package:teso/util/SizeConfig.dart';
|
||
|
|
||
|
class FirstTimeIntro extends StatefulWidget {
|
||
|
const FirstTimeIntro({Key key}) : super(key: key);
|
||
|
|
||
|
@override
|
||
|
_FirstTimeIntroState createState() => _FirstTimeIntroState();
|
||
|
}
|
||
|
|
||
|
class _FirstTimeIntroState extends State<FirstTimeIntro> {
|
||
|
@override
|
||
|
Widget build(BuildContext context) {
|
||
|
return Scaffold(
|
||
|
backgroundColor: Colors.transparent,
|
||
|
extendBodyBehindAppBar: false,
|
||
|
appBar: AppBar(
|
||
|
automaticallyImplyLeading: false,
|
||
|
toolbarHeight: 05,
|
||
|
backgroundColor: Colors.transparent,
|
||
|
),
|
||
|
body: GestureDetector(
|
||
|
onPanUpdate: (details) {
|
||
|
// Swiping in right direction.
|
||
|
if (details.delta.dx > 0) {
|
||
|
Navigator.pop(context, 0);
|
||
|
}
|
||
|
|
||
|
// Swiping in left direction.
|
||
|
if (details.delta.dx < 0) {
|
||
|
Navigator.pop(context, 2);
|
||
|
}
|
||
|
},
|
||
|
onTap: () => Navigator.pop(context, 1),
|
||
|
child: Container(
|
||
|
width: SizeConfig.blockSizeHorizontal * 100,
|
||
|
height: SizeConfig.blockSizeVertical * 100,
|
||
|
child: Image.asset(
|
||
|
"assets/images/firstTime.png",
|
||
|
fit: BoxFit.fitHeight,
|
||
|
),
|
||
|
),
|
||
|
),
|
||
|
);
|
||
|
}
|
||
|
}
|