Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Widget defaultDrawer(BuildContext context) {
- return Drawer(
- child: ListView(
- padding: EdgeInsets.zero,
- children: <Widget>[
- new DrawerHeader(
- child: Center(
- child: new Image.asset(
- "assets/logos/logo-color.png",
- ),
- ),
- ),
- ListTile(
- key: new Key("Home"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.home,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "Home",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {
- Navigator.push(
- context,
- MaterialPageRoute(
- builder: (context) => HomePage()
- ),
- );
- },
- ),
- ListTile(
- key: new Key("Ceremonies"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.graphic_eq,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "Ceremonies",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {
- Navigator.push(
- context,
- MaterialPageRoute(
- builder: (context) => ListCeremonies()
- ),
- );
- }, //TODO: Implement fungsi buat callback kalo mencet Ceremonies di drawer
- ),
- ListTile(
- key: new Key("Problems"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.warning,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "Problems",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {
- Navigator.push(
- context,
- MaterialPageRoute(
- builder: (context) => ListProblems()
- ),
- );
- },
- ),
- ListTile(
- key: new Key("Glossary"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.book,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "Glossary",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {
- Navigator.push(
- context,
- MaterialPageRoute(
- builder: (context) => GlossaryPage()
- ),
- );
- }, //TODO: Implement fungsi buat callback kalo mencet Glossary di drawer
- ),
- ListTile(
- key: new Key("Pop Quiz!"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.question_answer,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "Pop Quiz!",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {}, //TODO: Implement fungsi buat callback kalo mencet Pop Quiz di drawer
- ),
- ListTile(
- key: new Key("About"),
- title: Row(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment: CrossAxisAlignment.start,
- children: <Widget>[
- new Icon(
- Icons.info,
- color: hexToColor("#979797"),
- ),
- new Padding(
- padding: EdgeInsets.all(10.0),
- ),
- new Text(
- "About",
- style: TextStyle(
- color: hexToColor("#979797"),
- fontWeight: FontWeight.bold,
- fontSize: 20.0,
- ),
- ),
- ],
- ),
- onTap: () {
- Navigator.push(
- context,
- MaterialPageRoute(
- builder: (context) => AboutPage()
- ),
- );
- }, //TODO: Implement fungsi buat callback kalo mencet About di drawer
- ),
- ],
- ),
- );
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement