2021-01-16 03:32:41 +01:00
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
import 'package:dubp/dubp.dart';
|
2021-01-28 15:10:09 +01:00
|
|
|
import 'package:gecko/models/myWallets.dart';
|
2021-01-16 03:32:41 +01:00
|
|
|
import 'dart:io';
|
|
|
|
|
2021-01-28 15:10:09 +01:00
|
|
|
// ignore: must_be_immutable
|
|
|
|
class SettingsScreen extends StatelessWidget {
|
2021-01-16 03:32:41 +01:00
|
|
|
String generatedMnemonic;
|
|
|
|
bool walletIsGenerated = false;
|
|
|
|
NewWallet actualWallet;
|
|
|
|
String newWalletName;
|
|
|
|
|
|
|
|
bool hasError = false;
|
|
|
|
String validPin = 'NO PIN';
|
|
|
|
String currentText = "";
|
|
|
|
var pinColor = Colors.grey[300];
|
|
|
|
Directory appPath;
|
|
|
|
|
2021-01-28 15:10:09 +01:00
|
|
|
MyWalletsProvider _myWallets = MyWalletsProvider();
|
|
|
|
|
2021-01-16 03:32:41 +01:00
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
// getAppDirectory();
|
|
|
|
return Scaffold(
|
|
|
|
appBar: AppBar(
|
|
|
|
title: SizedBox(
|
|
|
|
height: 22,
|
|
|
|
child: Text('Paramètres'),
|
|
|
|
)),
|
|
|
|
body: Column(children: <Widget>[
|
|
|
|
SizedBox(height: 20),
|
|
|
|
Expanded(
|
|
|
|
child: Align(
|
|
|
|
alignment: Alignment.bottomCenter,
|
|
|
|
child: SizedBox(
|
|
|
|
height: 100,
|
|
|
|
width: 1000,
|
|
|
|
child: ElevatedButton(
|
|
|
|
style: ElevatedButton.styleFrom(
|
|
|
|
elevation: 5,
|
|
|
|
primary: Colors
|
|
|
|
.redAccent, //Color(0xffFFD68E), // background
|
|
|
|
onPrimary: Colors.black, // foreground
|
|
|
|
),
|
|
|
|
onPressed: () => {
|
|
|
|
print('Suppression de tous les wallets'),
|
2021-01-28 15:10:09 +01:00
|
|
|
_myWallets.deleteAllWallet(context)
|
2021-01-16 03:32:41 +01:00
|
|
|
},
|
|
|
|
child: Text(
|
|
|
|
"EFFACER TOUS MES PORTEFEUILLES, LE TEMPS DE L'ALPHA",
|
|
|
|
style: TextStyle(fontSize: 20)))))),
|
|
|
|
SizedBox(height: 50),
|
|
|
|
]));
|
|
|
|
}
|
|
|
|
}
|