mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-22 19:49:22 +00:00
Linter errors fixes. Move secrandom native to cw_core
This commit is contained in:
parent
c5ad751279
commit
30b77ebd58
13 changed files with 89 additions and 29 deletions
|
@ -1,5 +1,3 @@
|
|||
import 'dart:math';
|
||||
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:cw_core/crypto_amount_format.dart';
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ import 'dart:typed_data';
|
|||
import 'package:crypto/crypto.dart';
|
||||
import 'package:unorm_dart/unorm_dart.dart' as unorm;
|
||||
import 'package:cryptography/cryptography.dart' as cryptography;
|
||||
import 'package:cake_wallet/core/sec_random_native.dart';
|
||||
import 'package:cw_core/sec_random_native.dart';
|
||||
|
||||
const segwit = '100';
|
||||
final wordlist = englishWordlist;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import 'package:cw_core/transaction_priority.dart';
|
||||
import 'package:cake_wallet/generated/i18n.dart';
|
||||
//import 'package:cake_wallet/generated/i18n.dart';
|
||||
|
||||
class BitcoinTransactionPriority extends TransactionPriority {
|
||||
const BitcoinTransactionPriority({String title, int raw})
|
||||
|
@ -34,13 +34,13 @@ class BitcoinTransactionPriority extends TransactionPriority {
|
|||
|
||||
switch (this) {
|
||||
case BitcoinTransactionPriority.slow:
|
||||
label = '${S.current.transaction_priority_slow} ~24hrs';
|
||||
label = 'Slow ~24hrs'; // '${S.current.transaction_priority_slow} ~24hrs';
|
||||
break;
|
||||
case BitcoinTransactionPriority.medium:
|
||||
label = S.current.transaction_priority_medium;
|
||||
label = 'Medium'; // S.current.transaction_priority_medium;
|
||||
break;
|
||||
case BitcoinTransactionPriority.fast:
|
||||
label = S.current.transaction_priority_fast;
|
||||
label = 'Fast'; // S.current.transaction_priority_fast;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
@ -86,13 +86,13 @@ class LitecoinTransactionPriority extends BitcoinTransactionPriority {
|
|||
|
||||
switch (this) {
|
||||
case LitecoinTransactionPriority.slow:
|
||||
label = S.current.transaction_priority_slow;
|
||||
label = 'Slow'; // S.current.transaction_priority_slow;
|
||||
break;
|
||||
case LitecoinTransactionPriority.medium:
|
||||
label = S.current.transaction_priority_medium;
|
||||
label = 'Medium'; // S.current.transaction_priority_medium;
|
||||
break;
|
||||
case LitecoinTransactionPriority.fast:
|
||||
label = S.current.transaction_priority_fast;
|
||||
label = 'Fast'; // S.current.transaction_priority_fast;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
|
@ -326,6 +326,7 @@ class ElectrumClient {
|
|||
return subscription;
|
||||
} catch(e) {
|
||||
print(e.toString());
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -12,7 +12,6 @@ import 'package:cw_bitcoin/electrum_transaction_info.dart';
|
|||
import 'package:cw_core/pathForWallet.dart';
|
||||
import 'package:cw_bitcoin/address_to_output_script.dart';
|
||||
import 'package:cw_bitcoin/bitcoin_address_record.dart';
|
||||
import 'package:cw_bitcoin/bitcoin_amount_format.dart';
|
||||
import 'package:cw_bitcoin/electrum_balance.dart';
|
||||
import 'package:cw_bitcoin/bitcoin_mnemonic.dart';
|
||||
import 'package:cw_bitcoin/bitcoin_transaction_credentials.dart';
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
import 'package:bitcoin_flutter/bitcoin_flutter.dart' as bitcoin;
|
||||
import 'package:cw_bitcoin/bitcoin_mnemonic.dart';
|
||||
import 'package:cw_bitcoin/utils.dart';
|
||||
import 'package:cw_bitcoin/bitcoin_address_record.dart';
|
||||
import 'package:cw_bitcoin/electrum_wallet_addresses.dart';
|
||||
|
|
|
@ -21,7 +21,14 @@ packages:
|
|||
name: args
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.3.0"
|
||||
version: "1.6.0"
|
||||
asn1lib:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: asn1lib
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.6.5"
|
||||
async:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -123,14 +130,14 @@ packages:
|
|||
name: built_collection
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "5.1.1"
|
||||
version: "4.3.2"
|
||||
built_value:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: built_value
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "8.1.3"
|
||||
version: "7.1.0"
|
||||
characters:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -194,6 +201,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.5"
|
||||
cryptography:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: cryptography
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.4.1"
|
||||
cw_core:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -215,6 +229,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.5.0"
|
||||
encrypt:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: encrypt
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.0.3"
|
||||
fake_async:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -242,7 +263,7 @@ packages:
|
|||
name: fixnum
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.0"
|
||||
version: "0.10.11"
|
||||
flutter:
|
||||
dependency: "direct main"
|
||||
description: flutter
|
||||
|
@ -491,6 +512,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.1.8"
|
||||
quiver:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: quiver
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.5"
|
||||
rxdart:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -594,6 +622,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.3.0"
|
||||
unorm_dart:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: unorm_dart
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.2.0"
|
||||
vector_math:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
name: cw_bitcoin
|
||||
description: A new Flutter package project.
|
||||
version: 0.0.1
|
||||
author:
|
||||
homepage:
|
||||
publish_to: none
|
||||
author: Cake Wallet
|
||||
homepage: https://cakewallet.com
|
||||
|
||||
environment:
|
||||
sdk: ">=2.7.0 <3.0.0"
|
||||
|
@ -23,6 +24,9 @@ dependencies:
|
|||
url: https://github.com/cake-tech/bitcoin_flutter.git
|
||||
ref: cake
|
||||
rxdart: ^0.26.0
|
||||
unorm_dart: ^0.2.0
|
||||
cryptography: ^1.4.0
|
||||
encrypt: ^4.0.0
|
||||
|
||||
dev_dependencies:
|
||||
flutter_test:
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import 'package:cw_core/transaction_direction.dart';
|
||||
import 'package:cake_wallet/utils/mobx.dart';
|
||||
//import 'package:cake_wallet/utils/mobx.dart';
|
||||
import 'package:cw_core/keyable.dart';
|
||||
|
||||
abstract class TransactionInfo extends Object with Keyable {
|
||||
|
|
|
@ -21,7 +21,14 @@ packages:
|
|||
name: args
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.3.0"
|
||||
version: "1.6.0"
|
||||
asn1lib:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: asn1lib
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.8.1"
|
||||
async:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -147,14 +154,14 @@ packages:
|
|||
name: convert
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "3.0.1"
|
||||
version: "2.1.1"
|
||||
crypto:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: crypto
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "3.0.1"
|
||||
version: "2.1.5"
|
||||
dart_style:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -168,7 +175,14 @@ packages:
|
|||
name: dartx
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.8.0"
|
||||
version: "0.5.0"
|
||||
encrypt:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: encrypt
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.1.0"
|
||||
fake_async:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -234,7 +248,7 @@ packages:
|
|||
name: hive
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.6.0-nullsafety.2"
|
||||
version: "1.4.4+1"
|
||||
hive_generator:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
|
@ -403,6 +417,13 @@ packages:
|
|||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.3"
|
||||
pointycastle:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: pointycastle
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.0.1"
|
||||
pool:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -512,7 +533,7 @@ packages:
|
|||
name: time
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.0"
|
||||
version: "1.4.1"
|
||||
timing:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
name: cw_core
|
||||
description: A new Flutter package project.
|
||||
version: 0.0.1
|
||||
author:
|
||||
homepage:
|
||||
publish_to: none
|
||||
author: Cake Wallet
|
||||
homepage: https://cakewallet.com
|
||||
|
||||
environment:
|
||||
sdk: ">=2.7.0 <3.0.0"
|
||||
|
@ -16,6 +17,7 @@ dependencies:
|
|||
mobx: ^1.2.1+2
|
||||
flutter_mobx: ^1.1.0+2
|
||||
intl: ^0.17.0
|
||||
encrypt: ^4.0.0
|
||||
|
||||
dev_dependencies:
|
||||
flutter_test:
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
name: cw_monero
|
||||
description: A new flutter plugin project.
|
||||
version: 0.0.1
|
||||
author:
|
||||
homepage:
|
||||
publish_to: none
|
||||
author: Cake Wallet
|
||||
homepage: https://cakewallet.com
|
||||
|
||||
environment:
|
||||
sdk: ">=2.6.0 <3.0.0"
|
||||
|
|
Loading…
Reference in a new issue