diff --git a/app/build.gradle b/app/build.gradle
index 438f67a22ed..3bcac06aefa 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -19,8 +19,8 @@ android {
compileSdk compile_sdk_version
minSdkVersion min_sdk_version
targetSdkVersion compile_sdk_version
- versionCode 115
- versionName "0.39.5"
+ versionCode 116
+ versionName "0.40.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
ksp {
@@ -75,6 +75,7 @@ android {
resValue "string", "arbiscanApiKey", "Z43JN5434XVNA5D73UGPWKF26G5D9MGDPZ"
resValue "string", "gnosisscanApiKey", "V2J8YU15ZX9S1W3GTUV2HXM11TP2TUBRW4"
resValue "string", "ftmscanApiKey", "57YQ2GIRAZNV6M5HIJYYG3XQGGNIPVV8MF"
+ resValue "string", "basescanApiKey", "AKEWS351FN9P9E2CFPWRWQVGHYUP7W8SUF"
resValue "string", "is_release", "false"
resValue "string", "guidesUrl", "https://raw.githubusercontent.com/horizontalsystems/blockchain-crypto-guides/develop/index.json"
resValue "string", "faqUrl", "https://raw.githubusercontent.com/horizontalsystems/Unstoppable-Wallet-Website/master/src/faq.json"
@@ -113,6 +114,7 @@ android {
resValue "string", "arbiscanApiKey", "4QWW522BV13BJCZMXH1JIB2ESJ7MZTSJYI"
resValue "string", "gnosisscanApiKey", "KEXFAQKDUENZ5U9CW3ZKYJEJ84ZIHH9QTY"
resValue "string", "ftmscanApiKey", "JAWRPW27KEMVXMJJ9UKY63CVPH3X5V9SMP"
+ resValue "string", "basescanApiKey", "QU4RJVJXQCW812J3234EW9EV815TA6XC55"
resValue "string", "is_release", "true"
resValue "string", "guidesUrl", "https://raw.githubusercontent.com/horizontalsystems/blockchain-crypto-guides/v1.2/index.json"
resValue "string", "faqUrl", "https://raw.githubusercontent.com/horizontalsystems/Unstoppable-Wallet-Website/v1.3/src/faq.json"
@@ -179,6 +181,12 @@ android {
substitute module('com.tinder.scarlet:message-adapter-gson:0.1.12') using module('com.github.WalletConnect.Scarlet:message-adapter-gson:1.0.0')
substitute module('com.tinder.scarlet:lifecycle-android:0.1.12') using module('com.github.WalletConnect.Scarlet:lifecycle-android:1.0.0')
}
+
+ resolutionStrategy.eachDependency { details ->
+ if (details.requested.group == 'com.squareup.okhttp3') {
+ details.useVersion "4.12.0"
+ }
+ }
}
}
@@ -232,7 +240,7 @@ dependencies {
implementation 'com.squareup.retrofit2:adapter-rxjava2:2.11.0'
implementation 'com.squareup.retrofit2:converter-gson:2.11.0'
implementation 'com.squareup.retrofit2:converter-scalars:2.11.0'
- implementation 'com.squareup.okhttp3:logging-interceptor:4.11.0'
+ implementation 'com.squareup.okhttp3:logging-interceptor:4.12.0'
implementation 'com.google.code.gson:gson:2.10.1'
implementation "androidx.biometric:biometric:$biometric_version"
@@ -269,12 +277,12 @@ dependencies {
debugImplementation leakCanary
// Wallet kits
- implementation 'com.github.horizontalsystems:ton-kit-kmm:f1fd301'
+ implementation 'com.github.horizontalsystems:ton-kit-android:e907480'
implementation 'com.github.horizontalsystems:bitcoin-kit-android:47db768'
- implementation 'com.github.horizontalsystems:ethereum-kit-android:3d83900'
+ implementation 'com.github.horizontalsystems:ethereum-kit-android:a30cc3a71'
implementation 'com.github.horizontalsystems:blockchain-fee-rate-kit-android:1d3bd49'
implementation 'com.github.horizontalsystems:binance-chain-kit-android:c1509a2'
- implementation 'com.github.horizontalsystems:market-kit-android:636ca4d'
+ implementation 'com.github.horizontalsystems:market-kit-android:5fe87c2'
implementation 'com.github.horizontalsystems:solana-kit-android:ce738d8'
implementation 'com.github.horizontalsystems:tron-kit-android:dc3dca7'
// Zcash SDK
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index b671a4a0c4b..95bc213110f 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -357,6 +357,70 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/App.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/App.kt
index 1d21394b41b..ca81b8c1735 100644
--- a/app/src/main/java/io/horizontalsystems/bankwallet/core/App.kt
+++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/App.kt
@@ -26,7 +26,6 @@ import io.horizontalsystems.bankwallet.core.managers.AccountCleaner
import io.horizontalsystems.bankwallet.core.managers.AccountManager
import io.horizontalsystems.bankwallet.core.managers.AdapterManager
import io.horizontalsystems.bankwallet.core.managers.AppVersionManager
-import io.horizontalsystems.bankwallet.core.managers.BackgroundStateChangeListener
import io.horizontalsystems.bankwallet.core.managers.BackupManager
import io.horizontalsystems.bankwallet.core.managers.BalanceHiddenManager
import io.horizontalsystems.bankwallet.core.managers.BaseTokenManager
@@ -61,6 +60,8 @@ import io.horizontalsystems.bankwallet.core.managers.SubscriptionManager
import io.horizontalsystems.bankwallet.core.managers.SystemInfoManager
import io.horizontalsystems.bankwallet.core.managers.TermsManager
import io.horizontalsystems.bankwallet.core.managers.TokenAutoEnableManager
+import io.horizontalsystems.bankwallet.core.managers.TonAccountManager
+import io.horizontalsystems.bankwallet.core.managers.TonKitManager
import io.horizontalsystems.bankwallet.core.managers.TorManager
import io.horizontalsystems.bankwallet.core.managers.TransactionAdapterManager
import io.horizontalsystems.bankwallet.core.managers.TronAccountManager
@@ -141,7 +142,6 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
lateinit var btcBlockchainManager: BtcBlockchainManager
lateinit var wordsManager: WordsManager
lateinit var networkManager: INetworkManager
- lateinit var backgroundStateChangeListener: BackgroundStateChangeListener
lateinit var appConfigProvider: AppConfigProvider
lateinit var adapterManager: IAdapterManager
lateinit var transactionAdapterManager: TransactionAdapterManager
@@ -163,6 +163,7 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
lateinit var binanceKitManager: BinanceKitManager
lateinit var solanaKitManager: SolanaKitManager
lateinit var tronKitManager: TronKitManager
+ lateinit var tonKitManager: TonKitManager
lateinit var numberFormatter: IAppNumberFormatter
lateinit var feeCoinProvider: FeeTokenProvider
lateinit var accountCleaner: IAccountCleaner
@@ -275,6 +276,7 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
solanaKitManager = SolanaKitManager(appConfigProvider, solanaRpcSourceManager, solanaWalletManager, backgroundManager)
tronKitManager = TronKitManager(appConfigProvider, backgroundManager)
+ tonKitManager = TonKitManager(backgroundManager)
wordsManager = WordsManager(Mnemonic())
networkManager = NetworkManager()
@@ -318,6 +320,9 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
)
tronAccountManager.start()
+ val tonAccountManager = TonAccountManager(accountManager, walletManager, tonKitManager, tokenAutoEnableManager)
+ tonAccountManager.start()
+
systemInfoManager = SystemInfoManager(appConfigProvider)
languageManager = LanguageManager()
@@ -344,13 +349,23 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
binanceKitManager = binanceKitManager,
solanaKitManager = solanaKitManager,
tronKitManager = tronKitManager,
+ tonKitManager = tonKitManager,
backgroundManager = backgroundManager,
restoreSettingsManager = restoreSettingsManager,
coinManager = coinManager,
evmLabelManager = evmLabelManager,
localStorage = localStorage
)
- adapterManager = AdapterManager(walletManager, adapterFactory, btcBlockchainManager, evmBlockchainManager, binanceKitManager, solanaKitManager, tronKitManager)
+ adapterManager = AdapterManager(
+ walletManager,
+ adapterFactory,
+ btcBlockchainManager,
+ evmBlockchainManager,
+ binanceKitManager,
+ solanaKitManager,
+ tronKitManager,
+ tonKitManager,
+ )
transactionAdapterManager = TransactionAdapterManager(adapterManager, adapterFactory)
feeCoinProvider = FeeTokenProvider(marketKit)
@@ -358,13 +373,11 @@ class App : CoreApp(), WorkConfiguration.Provider, ImageLoaderFactory {
pinComponent = PinComponent(
pinSettingsStorage = pinSettingsStorage,
userManager = userManager,
- pinDbStorage = PinDbStorage(appDatabase.pinDao())
+ pinDbStorage = PinDbStorage(appDatabase.pinDao()),
+ backgroundManager = backgroundManager
)
- statsManager = StatsManager(appDatabase.statsDao(), localStorage, marketKit, appConfigProvider)
- backgroundStateChangeListener = BackgroundStateChangeListener(pinComponent, statsManager).apply {
- backgroundManager.registerListener(this)
- }
+ statsManager = StatsManager(appDatabase.statsDao(), localStorage, marketKit, appConfigProvider, backgroundManager)
rateAppManager = RateAppManager(walletManager, adapterManager, localStorage)
diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/Interfaces.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/Interfaces.kt
index 66b25457695..9e3ed99e954 100644
--- a/app/src/main/java/io/horizontalsystems/bankwallet/core/Interfaces.kt
+++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/Interfaces.kt
@@ -47,6 +47,7 @@ import io.horizontalsystems.marketkit.models.BlockchainType
import io.horizontalsystems.marketkit.models.Token
import io.horizontalsystems.marketkit.models.TokenQuery
import io.horizontalsystems.solanakit.models.FullTransaction
+import io.horizontalsystems.tonkit.FriendlyAddress
import io.horizontalsystems.tronkit.transaction.Fee
import io.reactivex.Flowable
import io.reactivex.Observable
@@ -62,7 +63,7 @@ import io.horizontalsystems.tronkit.models.Address as TronAddress
interface IAdapterManager {
val adaptersReadyObservable: Flowable