Replace prints by debugs logs
This commit is contained in:
parent
794d24e235
commit
b6703f48e6
|
@ -22,4 +22,4 @@ bool isTall;
|
|||
double ratio;
|
||||
|
||||
// Logger
|
||||
var logger = Logger();
|
||||
var log = Logger();
|
||||
|
|
|
@ -68,7 +68,6 @@ class CesiumPlusProvider with ChangeNotifier {
|
|||
List queryOptions = await _buildQuery(_pubkey);
|
||||
final response = await http.post((Uri.parse(queryOptions[0])),
|
||||
body: queryOptions[1], headers: queryOptions[2]);
|
||||
// print('RESULT CESIUM QUERY: ${response.body}'); //For debug
|
||||
final responseJson = json.decode(response.body);
|
||||
if (responseJson['hits']['hits'].toString() == '[]') {
|
||||
return '';
|
||||
|
@ -79,7 +78,6 @@ class CesiumPlusProvider with ChangeNotifier {
|
|||
return '';
|
||||
}
|
||||
_name = responseJson['hits']['hits'][0]['_source']['title'];
|
||||
print(_name);
|
||||
|
||||
return _name;
|
||||
}
|
||||
|
@ -88,7 +86,6 @@ class CesiumPlusProvider with ChangeNotifier {
|
|||
List queryOptions = await _buildQuery(_pubkey);
|
||||
final response = await http.post((Uri.parse(queryOptions[0])),
|
||||
body: queryOptions[1], headers: queryOptions[2]);
|
||||
// print('RESULT CESIUM QUERY: ${response.body}'); //For debug
|
||||
final responseJson = json.decode(response.body);
|
||||
if (responseJson['hits']['hits'].toString() == '[]') {
|
||||
return [File(appPath.path + '/default_avatar.png')];
|
||||
|
@ -103,21 +100,10 @@ class CesiumPlusProvider with ChangeNotifier {
|
|||
|
||||
var avatarFile =
|
||||
File('${(await getTemporaryDirectory()).path}/avatar$iAvatar.png');
|
||||
// final bool _isAvatarExist = await avatarFile.exists();
|
||||
// if (_isAvatarExist) {
|
||||
// await avatarFile.delete();
|
||||
// }
|
||||
await avatarFile.writeAsBytes(base64.decode(_avatar));
|
||||
iAvatar++;
|
||||
isComplete = true;
|
||||
|
||||
return [avatarFile];
|
||||
}
|
||||
|
||||
// isNameComplete() {
|
||||
// while (isComplete == false) {
|
||||
// print(isComplete);
|
||||
// Duration(milliseconds: 50);
|
||||
// }
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -27,7 +27,7 @@ class ChangePinProvider with ChangeNotifier {
|
|||
notifyListeners();
|
||||
return newWalletFile;
|
||||
} catch (e) {
|
||||
print('Impossible de changer le code PIN.');
|
||||
log.e('Impossible de changer le code PIN.');
|
||||
return badWallet;
|
||||
}
|
||||
}
|
||||
|
@ -36,7 +36,6 @@ class ChangePinProvider with ChangeNotifier {
|
|||
final Directory walletNameDirectory =
|
||||
Directory('${walletsDirectory.path}/$_name');
|
||||
final walletFile = File('${walletNameDirectory.path}/wallet.dewif');
|
||||
print(_newWalletFile);
|
||||
|
||||
walletFile.writeAsString('${_newWalletFile.dewif}');
|
||||
Navigator.pop(context);
|
||||
|
|
|
@ -79,8 +79,6 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
|
||||
final runesAsked = _mnemo.split(' ')[nbrWord].runes;
|
||||
List<int> runesAskedUnaccent = [];
|
||||
print(runesAsked);
|
||||
print(value.runes);
|
||||
for (int i in runesAsked) {
|
||||
if (i == 768 || i == 769 || i == 770 || i == 771) {
|
||||
continue;
|
||||
|
@ -92,11 +90,11 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
utf8.decode(runesAskedUnaccent).toLowerCase();
|
||||
final String unaccentedInputWord = removeDiacritics(value).toLowerCase();
|
||||
|
||||
print("Is $unaccentedAskedWord equal to input $unaccentedInputWord ?");
|
||||
log.i("Is $unaccentedAskedWord equal to input $unaccentedInputWord ?");
|
||||
if (unaccentedAskedWord == unaccentedInputWord ||
|
||||
value == 'triche' ||
|
||||
value == '3.14') {
|
||||
print('Word is OK');
|
||||
log.d('Word is OK');
|
||||
isAskedWordValid = true;
|
||||
askedWordColor = Colors.green[600];
|
||||
// walletNameFocus.nextFocus();
|
||||
|
@ -155,7 +153,7 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
this.actualWallet = await generateWallet(this.generatedMnemonic);
|
||||
walletIsGenerated = true;
|
||||
} catch (e) {
|
||||
print(e);
|
||||
log.e(e);
|
||||
}
|
||||
return generatedMnemonic;
|
||||
}
|
||||
|
@ -168,7 +166,7 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
secretCodeType: SecretCodeType.letters,
|
||||
);
|
||||
} catch (e) {
|
||||
print(e);
|
||||
log.e(e);
|
||||
}
|
||||
|
||||
mnemonicController.text = generatedMnemonic;
|
||||
|
@ -240,7 +238,7 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
cesiumPubkey.text = _walletPubkey;
|
||||
pin.text = actualWallet.pin;
|
||||
isPinChanged = true;
|
||||
print(_walletPubkey);
|
||||
log.d(_walletPubkey);
|
||||
}
|
||||
|
||||
Future importWallet(context, _cesiumID, _cesiumPWD) async {
|
||||
|
@ -291,20 +289,13 @@ class GenerateWalletsProvider with ChangeNotifier {
|
|||
int _nbr = 1;
|
||||
|
||||
for (word in _sentance.split(' ')) {
|
||||
// print(word);
|
||||
_wordsList.add("$_nbr:$word");
|
||||
_nbr++;
|
||||
}
|
||||
// notifyListeners();
|
||||
|
||||
return _wordsList;
|
||||
}
|
||||
|
||||
// void makeError() {
|
||||
// var tata = File(appPath.path + '/ddfhjftjfg');
|
||||
// tata.readAsLinesSync();
|
||||
// }
|
||||
|
||||
void reloadBuild() {
|
||||
notifyListeners();
|
||||
}
|
||||
|
|
|
@ -36,7 +36,7 @@ class HistoryProvider with ChangeNotifier {
|
|||
try {
|
||||
barcode = await scanner.scan();
|
||||
} catch (e) {
|
||||
print(e);
|
||||
log.e(e);
|
||||
return 'false';
|
||||
}
|
||||
if (barcode != null) {
|
||||
|
@ -72,7 +72,7 @@ class HistoryProvider with ChangeNotifier {
|
|||
if (regExp.hasMatch(pubkey) == true &&
|
||||
pubkey.length > 42 &&
|
||||
pubkey.length < 45) {
|
||||
print("C'est une pubkey !!!");
|
||||
log.d("C'est une pubkey !!!");
|
||||
|
||||
this.pubkey = pubkey;
|
||||
getShortPubkey(pubkey);
|
||||
|
@ -157,8 +157,6 @@ class HistoryProvider with ChangeNotifier {
|
|||
final date = formatter.format(dateBrut);
|
||||
transBC[i].add(transaction['writtenTime']);
|
||||
transBC[i].add(date);
|
||||
// print(
|
||||
// "DEBUG date et comment: ${date.toString()} -- ${transaction['comment'].toString()}");
|
||||
final int amountBrut = int.parse(output.split(':')[0]);
|
||||
final base = int.parse(output.split(':')[1]);
|
||||
final int applyBase = base - currentBase;
|
||||
|
@ -191,9 +189,6 @@ class HistoryProvider with ChangeNotifier {
|
|||
pageInfo = result.data['txsHistoryBc']['both']['pageInfo'];
|
||||
|
||||
fetchMoreCursor = pageInfo['endCursor'];
|
||||
print('hasPreviousPage: ' + pageInfo['hasPreviousPage'].toString());
|
||||
print('hasNextPage: ' + pageInfo['hasNextPage'].toString());
|
||||
|
||||
if (fetchMoreCursor != null) {
|
||||
opts = FetchMoreOptions(
|
||||
variables: {'cursor': fetchMoreCursor},
|
||||
|
@ -211,12 +206,12 @@ class HistoryProvider with ChangeNotifier {
|
|||
);
|
||||
}
|
||||
|
||||
print(
|
||||
log.d(
|
||||
"###### DEBUG H Parse blockchainTX list. Cursor: $fetchMoreCursor ######");
|
||||
if (fetchMoreCursor != null) {
|
||||
transBC = parseHistory(blockchainTX, _pubkey);
|
||||
} else {
|
||||
print("###### DEBUG H - Début de l'historique");
|
||||
log.i("###### DEBUG H - Début de l'historique");
|
||||
}
|
||||
|
||||
return opts;
|
||||
|
|
|
@ -53,10 +53,10 @@ class HomeProvider with ChangeNotifier {
|
|||
|
||||
do {
|
||||
i++;
|
||||
print(i.toString() + ' ème essai de recherche de endpoint GVA.');
|
||||
print('Try GVA endpoint: ${_listEndpoints[i]}');
|
||||
log.d(i.toString() + ' ème essai de recherche de endpoint GVA.');
|
||||
log.d('Try GVA endpoint: ${_listEndpoints[i]}');
|
||||
if (i > 2) {
|
||||
print('NO VALID GVA ENDPOINT FOUND');
|
||||
log.e('NO VALID GVA ENDPOINT FOUND');
|
||||
_endpoint = 'HS';
|
||||
break;
|
||||
}
|
||||
|
@ -71,21 +71,21 @@ class HomeProvider with ChangeNotifier {
|
|||
_endpoint = _listEndpoints[i];
|
||||
_statusCode = response.statusCode;
|
||||
} on TimeoutException catch (_) {
|
||||
print('This endpoint is timeout, next');
|
||||
log.e('This endpoint is timeout, next');
|
||||
_statusCode = 50;
|
||||
continue;
|
||||
} on SocketException catch (_) {
|
||||
print('This endpoint is a bad endpoint, next');
|
||||
log.e('This endpoint is a bad endpoint, next');
|
||||
_statusCode = 70;
|
||||
continue;
|
||||
} on Exception {
|
||||
print('Unknown error');
|
||||
log.e('Unknown error');
|
||||
_statusCode = 60;
|
||||
continue;
|
||||
}
|
||||
} while (_statusCode != 400);
|
||||
|
||||
print('ENDPOINT: ' + _endpoint);
|
||||
log.i('ENDPOINT: ' + _endpoint);
|
||||
return _endpoint;
|
||||
}
|
||||
|
||||
|
|
|
@ -51,37 +51,30 @@ class MyWalletsProvider with ChangeNotifier {
|
|||
final List _walletList = readAllWallets(0);
|
||||
|
||||
if (_walletList.isEmpty) {
|
||||
print('No wallets detected');
|
||||
log.i('No wallets detected');
|
||||
return false;
|
||||
} else {
|
||||
print('Some wallets have been detected.');
|
||||
log.i('Some wallets have been detected.');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
List readAllWallets(int _chest) {
|
||||
print(walletsDirectory.path);
|
||||
log.d(walletsDirectory.path);
|
||||
|
||||
listWallets = [];
|
||||
|
||||
// int i = 0;
|
||||
File _walletConfig = File('${walletsDirectory.path}/$_chest/list.conf');
|
||||
_walletConfig.readAsLinesSync().forEach((element) {
|
||||
print(element);
|
||||
log.i(element);
|
||||
listWallets.add(WalletData(element));
|
||||
// listWallets += "${element.split(':')[0]}:${element.split(':')[1]}:${element.split(':')[2]}"
|
||||
});
|
||||
// listWallets.forEach((e) {
|
||||
// print(e.name);
|
||||
// });
|
||||
// print(listWallets);
|
||||
|
||||
return listWallets;
|
||||
}
|
||||
|
||||
WalletData getWalletData(String _id) {
|
||||
int chest = int.parse(_id.split(':')[0]);
|
||||
// int nbr = int.parse(_id.split(':')[1]);
|
||||
final _walletConfig = File('${walletsDirectory.path}/$chest/list.conf');
|
||||
|
||||
return WalletData(_walletConfig
|
||||
|
@ -97,12 +90,11 @@ class MyWalletsProvider with ChangeNotifier {
|
|||
}
|
||||
|
||||
defaultWallet = getWalletData(defaultWalletFile.readAsStringSync());
|
||||
print("found default wallet $defaultWallet");
|
||||
}
|
||||
|
||||
Future<int> deleteAllWallet(context) async {
|
||||
try {
|
||||
print('DELETE THAT ?: $walletsDirectory');
|
||||
log.w('DELETE THAT ?: $walletsDirectory');
|
||||
|
||||
final bool _answer = await _confirmDeletingAllWallets(context);
|
||||
|
||||
|
@ -176,7 +168,6 @@ class MyWalletsProvider with ChangeNotifier {
|
|||
'\n0:$_newWalletNbr:$_name:$_newDerivationNbr',
|
||||
mode: FileMode.append);
|
||||
|
||||
print(await _walletConfig.readAsString());
|
||||
notifyListeners();
|
||||
|
||||
Navigator.pop(context);
|
||||
|
|
|
@ -38,9 +38,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
);
|
||||
|
||||
if (regExp.hasMatch(_pin) == true && _pin.length == _pinLenght) {
|
||||
print("Le format du code PIN est correct.");
|
||||
} else {
|
||||
print('Format de code PIN invalide');
|
||||
return 'false';
|
||||
}
|
||||
if (derivation != -1) {
|
||||
|
@ -53,8 +51,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
|
||||
return _pubkey;
|
||||
} catch (e) {
|
||||
print('Bad PIN code !');
|
||||
print(e);
|
||||
log.w('Bad PIN code !\n' + e);
|
||||
notifyListeners();
|
||||
|
||||
return 'false';
|
||||
|
@ -66,8 +63,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
notifyListeners();
|
||||
return _pubkey;
|
||||
} catch (e) {
|
||||
print('Bad PIN code !');
|
||||
print(e);
|
||||
log.w('Bad PIN code !\n' + e);
|
||||
notifyListeners();
|
||||
|
||||
return 'false';
|
||||
|
@ -96,7 +92,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
throw 'Bad pubkey';
|
||||
}
|
||||
} catch (e) {
|
||||
print('ERROR READING FILE: $e');
|
||||
log.e('ERROR READING FILE: $e');
|
||||
this.pubkey.clear();
|
||||
// notifyListeners();
|
||||
return 'bad';
|
||||
|
@ -113,7 +109,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
throw false;
|
||||
}
|
||||
} catch (e) {
|
||||
print('ERROR READING FILE: $e');
|
||||
log.e('ERROR READING FILE: $e');
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
@ -299,7 +295,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
// notifyListeners();
|
||||
return newWalletFile;
|
||||
} catch (e) {
|
||||
print('Impossible de changer le code PIN.');
|
||||
log.e('Impossible de changer le code PIN.');
|
||||
return badWallet;
|
||||
}
|
||||
}
|
||||
|
@ -308,7 +304,6 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
final Directory walletNameDirectory =
|
||||
Directory('${walletsDirectory.path}/$_name');
|
||||
final walletFile = File('${walletNameDirectory.path}/wallet.dewif');
|
||||
print(_newWalletFile);
|
||||
|
||||
walletFile.writeAsString('${_newWalletFile.dewif}');
|
||||
Navigator.pop(context);
|
||||
|
@ -365,7 +360,7 @@ class WalletOptionsProvider with ChangeNotifier {
|
|||
_image = File(pickedFile.path);
|
||||
return _image;
|
||||
} else {
|
||||
print('No image selected.');
|
||||
log.w('No image selected.');
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -34,8 +34,7 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
|||
HistoryProvider _historyProvider = Provider.of<HistoryProvider>(context);
|
||||
HomeProvider _homeProvider = Provider.of<HomeProvider>(context);
|
||||
this._outputPubkey.text = _historyProvider.pubkey;
|
||||
print('Build pubkey : ' + _historyProvider.pubkey);
|
||||
// _historyProvider.snackNode(context);
|
||||
log.i('Build pubkey : ' + _historyProvider.pubkey);
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {});
|
||||
|
||||
return Scaffold(
|
||||
|
@ -58,7 +57,7 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
|||
autofocus: true,
|
||||
controller: _homeProvider.searchQuery,
|
||||
onChanged: (text) {
|
||||
print("Clé tappé: $text");
|
||||
log.d("Clé tappé: $text");
|
||||
final String searchResult =
|
||||
_historyProvider.isPubkey(context, text);
|
||||
if (searchResult != '') {
|
||||
|
@ -114,7 +113,6 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
|||
// HistoryProvider _historyProvider = Provider.of<HistoryProvider>(context);
|
||||
CesiumPlusProvider _cesiumPlusProvider =
|
||||
Provider.of<CesiumPlusProvider>(context);
|
||||
print("I'M HERE 1");
|
||||
bool _isFirstExec = true;
|
||||
return Expanded(
|
||||
child: Column(
|
||||
|
@ -131,18 +129,14 @@ class HistoryScreen extends StatelessWidget with ChangeNotifier {
|
|||
},
|
||||
),
|
||||
builder: (QueryResult result, {fetchMore, refetch}) {
|
||||
print("I'M HERE 2 ! $_isFirstExec");
|
||||
// print(result.source.isEager);
|
||||
|
||||
if (result.isLoading && result.data == null) {
|
||||
print("I'M HERE 3 !");
|
||||
return const Center(
|
||||
child: CircularProgressIndicator(),
|
||||
);
|
||||
}
|
||||
|
||||
if (result.hasException) {
|
||||
print('Error GVA: ' + result.exception.toString());
|
||||
log.e('Error GVA: ' + result.exception.toString());
|
||||
return Column(children: <Widget>[
|
||||
SizedBox(height: 50),
|
||||
Text(
|
||||
|
|
|
@ -97,7 +97,7 @@ class HomeScreen extends StatelessWidget {
|
|||
autofocus: true,
|
||||
controller: _homeProvider.searchQuery,
|
||||
onChanged: (text) {
|
||||
print("Clé tappé: $text");
|
||||
log.d("Clé tappé: $text");
|
||||
final String searchResult =
|
||||
_historyProvider.isPubkey(context, text);
|
||||
if (searchResult != '') {
|
||||
|
|
|
@ -24,9 +24,6 @@ class GenerateWalletsScreen extends StatelessWidget {
|
|||
Provider.of<GenerateWalletsProvider>(context);
|
||||
_generateWalletProvider.generateMnemonic();
|
||||
|
||||
// _generateWalletProvider.makeError();
|
||||
print('IS GENERATED ? : ' +
|
||||
_generateWalletProvider.walletIsGenerated.toString());
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: SizedBox(
|
||||
|
|
|
@ -48,7 +48,6 @@ class ImportWalletScreen extends StatelessWidget {
|
|||
_debounce.cancel();
|
||||
_debounce =
|
||||
Timer(const Duration(milliseconds: 200), () {
|
||||
print("ID Cesium tappé: $text");
|
||||
_generateWalletProvider
|
||||
.generateCesiumWalletPubkey(text,
|
||||
_generateWalletProvider.cesiumPWD.text)
|
||||
|
@ -86,7 +85,6 @@ class ImportWalletScreen extends StatelessWidget {
|
|||
_debounce.cancel();
|
||||
_debounce =
|
||||
Timer(const Duration(milliseconds: 200), () {
|
||||
print("ID Cesium tappé: $text");
|
||||
_generateWalletProvider
|
||||
.generateCesiumWalletPubkey(
|
||||
_generateWalletProvider.cesiumID.text,
|
||||
|
|
|
@ -9,8 +9,7 @@ import 'package:flutter/material.dart';
|
|||
import 'package:gecko/screens/myWallets/walletOptions.dart';
|
||||
import 'package:pin_code_fields/pin_code_fields.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
// import 'package:gecko/models/home.dart';
|
||||
// import 'package:provider/provider.dart';
|
||||
import 'package:gecko/globals.dart';
|
||||
|
||||
// ignore: must_be_immutable
|
||||
class UnlockingWallet extends StatelessWidget {
|
||||
|
@ -125,7 +124,7 @@ class UnlockingWallet extends StatelessWidget {
|
|||
)
|
||||
],
|
||||
onCompleted: (_pin) async {
|
||||
print("Completed");
|
||||
log.d("Completed");
|
||||
final resultWallet = await _walletOptions.readLocalWallet(
|
||||
context, this.wallet, _pin.toUpperCase(), _pinLenght);
|
||||
if (resultWallet == 'bad') {
|
||||
|
@ -149,7 +148,6 @@ class UnlockingWallet extends StatelessWidget {
|
|||
if (pinColor != Color(0xFFA4B600)) {
|
||||
pinColor = Color(0xFFA4B600);
|
||||
}
|
||||
print(value);
|
||||
},
|
||||
)),
|
||||
);
|
||||
|
|
|
@ -5,6 +5,7 @@ import 'package:gecko/models/walletOptions.dart';
|
|||
import 'dart:async';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:gecko/globals.dart';
|
||||
|
||||
// ignore: must_be_immutable
|
||||
class WalletOptionsOld extends StatelessWidget with ChangeNotifier {
|
||||
|
@ -21,15 +22,12 @@ class WalletOptionsOld extends StatelessWidget with ChangeNotifier {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]);
|
||||
print("Build walletOptions");
|
||||
log.d("Build walletOptions");
|
||||
WalletOptionsProvider _walletOptions =
|
||||
Provider.of<WalletOptionsProvider>(context);
|
||||
MyWalletsProvider _myWalletProvider =
|
||||
Provider.of<MyWalletsProvider>(context);
|
||||
|
||||
// _walletOptions.isWalletUnlock = false;
|
||||
print("Is unlock ? ${_walletOptions.isWalletUnlock}");
|
||||
|
||||
final int _currentChest = _myWalletProvider.getCurrentChest();
|
||||
|
||||
return WillPopScope(
|
||||
|
|
|
@ -22,7 +22,7 @@ class WalletOptions extends StatelessWidget {
|
|||
@override
|
||||
Widget build(BuildContext context) {
|
||||
SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]);
|
||||
print("Build walletOptions");
|
||||
log.d("Build walletOptions");
|
||||
WalletOptionsProvider _walletOptions =
|
||||
Provider.of<WalletOptionsProvider>(context);
|
||||
MyWalletsProvider _myWalletProvider =
|
||||
|
@ -55,10 +55,7 @@ class WalletOptions extends StatelessWidget {
|
|||
|
||||
int currentChest = _myWalletProvider.getCurrentChest();
|
||||
|
||||
print('roooooooooooooo');
|
||||
print("$currentChest:${wallet.number}");
|
||||
|
||||
// print(_walletOptions.generateQRcode(_walletOptions.pubkey.text));
|
||||
log.d("$currentChest:${wallet.number}");
|
||||
|
||||
return WillPopScope(
|
||||
onWillPop: () {
|
||||
|
@ -111,7 +108,6 @@ class WalletOptions extends StatelessWidget {
|
|||
InkWell(
|
||||
onTap: () async {
|
||||
await _walletOptions.changeAvatar();
|
||||
print('CHANGE AVATAR');
|
||||
},
|
||||
child: Image.asset(
|
||||
'assets/chopp-gecko2.png',
|
||||
|
@ -119,7 +115,6 @@ class WalletOptions extends StatelessWidget {
|
|||
InkWell(
|
||||
onTap: () async {
|
||||
await _walletOptions.changeAvatar();
|
||||
print('CHANGE AVATAR');
|
||||
},
|
||||
child: Column(children: <Widget>[
|
||||
Image.asset(
|
||||
|
@ -127,14 +122,12 @@ class WalletOptions extends StatelessWidget {
|
|||
),
|
||||
SizedBox(height: 100)
|
||||
])),
|
||||
// SizedBox(width: 20),
|
||||
Column(children: <Widget>[
|
||||
Row(children: <Widget>[
|
||||
Column(children: <Widget>[
|
||||
SizedBox(
|
||||
width: 260,
|
||||
child: TextField(
|
||||
// autofocus: true,
|
||||
focusNode: _walletOptions.walletNameFocus,
|
||||
enabled: _walletOptions.isEditing,
|
||||
controller: _walletOptions.nameController,
|
||||
|
@ -172,8 +165,6 @@ class WalletOptions extends StatelessWidget {
|
|||
return Text('Loading');
|
||||
}
|
||||
|
||||
print(result);
|
||||
|
||||
// List repositories = result.data['viewer']['repositories']['nodes'];
|
||||
String wBalanceUD;
|
||||
if (result.data['balance'] == null) {
|
||||
|
|
|
@ -88,10 +88,6 @@ class WalletsHome extends StatelessWidget {
|
|||
}
|
||||
|
||||
List _listWallets = _myWalletProvider.listWallets;
|
||||
// final int nbrOfWallets = _listWallets.length;
|
||||
// print(_listWallets);
|
||||
// print("${_listWallets[0].split(':')[0]}:${_listWallets[0].split(':')[2]}");
|
||||
// print(defaultWallet);
|
||||
|
||||
return GridView.count(
|
||||
crossAxisCount: 2,
|
||||
|
|
|
@ -110,14 +110,10 @@ class OnboardingStepFourteen extends StatelessWidget {
|
|||
)
|
||||
],
|
||||
onCompleted: (_pin) async {
|
||||
print("Completed");
|
||||
// final resultWallet = await _walletOptions.readLocalWallet(
|
||||
// _walletNbr, _pin.toUpperCase(), _pinLenght, _derivation);
|
||||
final bool resultWallet = await _walletOptions.checkPinOK(
|
||||
generatedWallet.dewif, _pin.toUpperCase(), _pinLenght);
|
||||
if (resultWallet) {
|
||||
pinColor = Colors.green[500];
|
||||
print(generatedWallet.pin);
|
||||
await _generateWalletProvider.storeHDWChest(
|
||||
generatedWallet, 'Mon portefeuille courant', context);
|
||||
_myWalletProvider.readAllWallets(_currentChest);
|
||||
|
@ -140,7 +136,6 @@ class OnboardingStepFourteen extends StatelessWidget {
|
|||
if (pinColor != Color(0xFFA4B600)) {
|
||||
pinColor = Color(0xFFA4B600);
|
||||
}
|
||||
print(value);
|
||||
},
|
||||
)),
|
||||
);
|
||||
|
|
|
@ -5,6 +5,7 @@ import 'package:gecko/models/myWallets.dart';
|
|||
import 'package:gecko/screens/myWallets/generateWallets.dart';
|
||||
import 'dart:io';
|
||||
import 'package:gecko/screens/myWallets/importWallet.dart';
|
||||
import 'package:gecko/globals.dart';
|
||||
|
||||
// ignore: must_be_immutable
|
||||
class SettingsScreen extends StatelessWidget {
|
||||
|
@ -85,7 +86,7 @@ class SettingsScreen extends StatelessWidget {
|
|||
onPrimary: Colors.black, // foreground
|
||||
),
|
||||
onPressed: () async => {
|
||||
print('Suppression de tous les wallets'),
|
||||
log.i('Suppression de tous les wallets'),
|
||||
await _myWallets.deleteAllWallet(context)
|
||||
},
|
||||
child: Text(
|
||||
|
|
Loading…
Reference in New Issue