Skip to content
Snippets Groups Projects
Commit ce538ffd authored by Benoît Harrault's avatar Benoît Harrault
Browse files

Merge branch '57-add-confirmation-on-restart-game-button' into 'master'

Resolve "Add confirmation on restart game button"

Closes #57

See merge request !55
parents 247e5e84 9dd6b9bf
No related branches found
No related tags found
1 merge request!55Resolve "Add confirmation on restart game button"
Pipeline #2454 failed
org.gradle.jvmargs=-Xmx1536M
android.useAndroidX=true
android.enableJetifier=true
app.versionName=0.1.0
app.versionCode=49
app.versionName=0.1.1
app.versionCode=50
Move restart game button to first place, triggered with long press
Déplacement du bouton de retour au menu en première position, activation par appui long
......@@ -76,6 +76,24 @@ class _HomeState extends State<Home> {
if (myProvider.gameIsRunning) {
menuActions = [
FlatButton(
child: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(4),
border: Border.all(
color: Colors.blue,
width: 4,
),
),
margin: EdgeInsets.all(8),
child: Image(
image: AssetImage('assets/icons/button_back.png'),
fit: BoxFit.fill
),
),
onLongPress: () => GameUtils.resetGame(myProvider),
),
Spacer(flex: 6),
FlatButton(
child: Container(
decoration: BoxDecoration(
......@@ -108,6 +126,7 @@ class _HomeState extends State<Home> {
),
onPressed: () => GameUtils.showTip(myProvider),
),
Spacer(),
FlatButton(
child: Container(
decoration: BoxDecoration(
......@@ -127,23 +146,6 @@ class _HomeState extends State<Home> {
myProvider.toggleShowConflicts();
},
),
FlatButton(
child: Container(
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(4),
border: Border.all(
color: Colors.blue,
width: 4,
),
),
margin: EdgeInsets.all(8),
child: Image(
image: AssetImage('assets/icons/button_back.png'),
fit: BoxFit.fill
),
),
onPressed: () => GameUtils.resetGame(myProvider),
),
];
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment