Created
November 10, 2019 10:41
-
-
Save lamberger/2732ff3b93ce5bb052cf89decba1c349 to your computer and use it in GitHub Desktop.
Floatingbutton
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Widget build(BuildContext context) { | |
| return Scaffold( | |
| appBar: AppBar(title: Text('Välkommen...')), | |
| floatingActionButton: Padding( | |
| padding: const EdgeInsets.all(16.0), | |
| child: FloatingActionButton.extended( | |
| onPressed: () { | |
| // Add your onPressed code here! | |
| Navigator.push( | |
| context, | |
| MaterialPageRoute(builder: (context) => Info()), | |
| ); | |
| }, | |
| label: Padding( | |
| padding: const EdgeInsets.all(8.0), | |
| child: Text('Gå vidare'), | |
| ), | |
| icon: Icon(Icons.thumb_up), | |
| tooltip: 'Some tooltip...', | |
| backgroundColor: Colors.red, | |
| splashColor: Colors.blue, | |
| ), | |
| ), | |
| ); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment