diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BinanceAdapter.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BinanceAdapter.kt index 88a27d8bd9a..6a258625a2c 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BinanceAdapter.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BinanceAdapter.kt @@ -98,11 +98,11 @@ class BinanceAdapter( transactionType: FilterTransactionType, address: String?, ): Flowable> = when (address) { - null -> getTransactionRecordsFlowable(token, transactionType) + null -> getTransactionRecordsFlowable(transactionType) else -> Flowable.empty() } - private fun getTransactionRecordsFlowable(token: Token?, transactionType: FilterTransactionType): Flowable> { + private fun getTransactionRecordsFlowable(transactionType: FilterTransactionType): Flowable> { return try { val filter = getBinanceTransactionTypeFilter(transactionType) asset.getTransactionsFlowable(filter).map { it.map { transactionRecord(it) } } @@ -118,11 +118,15 @@ class BinanceAdapter( transactionType: FilterTransactionType, address: String?, ) = when (address) { - null -> getTransactionsAsync(from, token, limit, transactionType) + null -> getTransactionsAsync(from, limit, transactionType) else -> Single.just(listOf()) } - private fun getTransactionsAsync(from: TransactionRecord?, token: Token?, limit: Int, transactionType: FilterTransactionType): Single> { + private fun getTransactionsAsync( + from: TransactionRecord?, + limit: Int, + transactionType: FilterTransactionType + ): Single> { return try { val filter = getBinanceTransactionTypeFilter(transactionType) binanceKit diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BitcoinBaseAdapter.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BitcoinBaseAdapter.kt index 77fe4832991..5c138a9add5 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BitcoinBaseAdapter.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/adapters/BitcoinBaseAdapter.kt @@ -117,11 +117,11 @@ abstract class BitcoinBaseAdapter( transactionType: FilterTransactionType, address: String?, ): Flowable> = when (address) { - null -> getTransactionRecordsFlowable(token, transactionType) + null -> getTransactionRecordsFlowable(transactionType) else -> Flowable.empty() } - private fun getTransactionRecordsFlowable(token: Token?, transactionType: FilterTransactionType): Flowable> { + private fun getTransactionRecordsFlowable(transactionType: FilterTransactionType): Flowable> { val observable: Observable> = when (transactionType) { FilterTransactionType.All -> { transactionRecordsSubject @@ -190,13 +190,12 @@ abstract class BitcoinBaseAdapter( transactionType: FilterTransactionType, address: String?, ) = when (address) { - null -> getTransactionsAsync(from, token, limit, transactionType) + null -> getTransactionsAsync(from, limit, transactionType) else -> Single.just(listOf()) } private fun getTransactionsAsync( from: TransactionRecord?, - token: Token?, limit: Int, transactionType: FilterTransactionType ): Single> { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_31_32.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_31_32.kt index c09ee9d4f76..4df80c0c256 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_31_32.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_31_32.kt @@ -5,15 +5,15 @@ import androidx.sqlite.db.SupportSQLiteDatabase object Migration_31_32 : Migration(31, 32) { - override fun migrate(database: SupportSQLiteDatabase) { - createTableActiveAccount(database) - createTableRestoreSettings(database) - - handleZcashAccount(database) - updateAccountRecordTable(database) - moveCoinSettingsFromBlockchainSettingsToWallet(database) - setActiveAccount(database) - setAccountUserFriendlyName(database) + override fun migrate(db: SupportSQLiteDatabase) { + createTableActiveAccount(db) + createTableRestoreSettings(db) + + handleZcashAccount(db) + updateAccountRecordTable(db) + moveCoinSettingsFromBlockchainSettingsToWallet(db) + setActiveAccount(db) + setAccountUserFriendlyName(db) } private fun handleZcashAccount(database: SupportSQLiteDatabase) { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_32_33.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_32_33.kt index 7e9cd4a7935..4f92d953928 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_32_33.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_32_33.kt @@ -5,9 +5,9 @@ import androidx.sqlite.db.SupportSQLiteDatabase object Migration_32_33 : Migration(32, 33) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("UPDATE `EnabledWallet` SET `coinSettingsId` = 'derivation:bip49' WHERE `coinId` IN ('bitcoin', 'litecoin') AND `coinSettingsId` = ''") - database.execSQL("UPDATE `EnabledWallet` SET `coinSettingsId` = 'bitcoinCashCoinType:type145' WHERE `coinId` IN ('bitcoinCash') AND `coinSettingsId` = ''") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("UPDATE `EnabledWallet` SET `coinSettingsId` = 'derivation:bip49' WHERE `coinId` IN ('bitcoin', 'litecoin') AND `coinSettingsId` = ''") + db.execSQL("UPDATE `EnabledWallet` SET `coinSettingsId` = 'bitcoinCashCoinType:type145' WHERE `coinId` IN ('bitcoinCash') AND `coinSettingsId` = ''") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_33_34.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_33_34.kt index 1356e66df57..9c67036df77 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_33_34.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_33_34.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_33_34 : Migration(33, 34) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE `AccountSettingRecord` (`accountId` TEXT NOT NULL, `key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`accountId`, `key`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE `AccountSettingRecord` (`accountId` TEXT NOT NULL, `key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`accountId`, `key`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_34_35.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_34_35.kt index da5e5519084..d3ace631c7a 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_34_35.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_34_35.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_34_35 : Migration(34, 35) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWalletCache` (`coinId` TEXT NOT NULL, `coinSettingsId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `balance` TEXT NOT NULL, `balanceLocked` TEXT NOT NULL, PRIMARY KEY(`coinId`, `coinSettingsId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWalletCache` (`coinId` TEXT NOT NULL, `coinSettingsId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `balance` TEXT NOT NULL, `balanceLocked` TEXT NOT NULL, PRIMARY KEY(`coinId`, `coinSettingsId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_35_36.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_35_36.kt index 022c151e0f9..8591e97b978 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_35_36.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_35_36.kt @@ -4,15 +4,15 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_35_36 : Migration(35, 36) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `CustomToken` (`coinName` TEXT NOT NULL, `coinCode` TEXT NOT NULL, `coinType` TEXT NOT NULL, `decimal` INTEGER NOT NULL, PRIMARY KEY(`coinType`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `CustomToken` (`coinName` TEXT NOT NULL, `coinCode` TEXT NOT NULL, `coinType` TEXT NOT NULL, `decimal` INTEGER NOT NULL, PRIMARY KEY(`coinType`))") - database.execSQL("ALTER TABLE FavoriteCoin RENAME TO TempFavoriteCoin") - database.execSQL("CREATE TABLE IF NOT EXISTS `FavoriteCoin` (`coinUid` TEXT NOT NULL, PRIMARY KEY(`coinUid`))") - database.execSQL("INSERT INTO FavoriteCoin (`coinUid`) SELECT `coinType` FROM TempFavoriteCoin") + db.execSQL("ALTER TABLE FavoriteCoin RENAME TO TempFavoriteCoin") + db.execSQL("CREATE TABLE IF NOT EXISTS `FavoriteCoin` (`coinUid` TEXT NOT NULL, PRIMARY KEY(`coinUid`))") + db.execSQL("INSERT INTO FavoriteCoin (`coinUid`) SELECT `coinType` FROM TempFavoriteCoin") - database.execSQL("DROP TABLE TempFavoriteCoin") - database.execSQL("DROP TABLE SubscriptionJob") - database.execSQL("DROP TABLE PriceAlert") + db.execSQL("DROP TABLE TempFavoriteCoin") + db.execSQL("DROP TABLE SubscriptionJob") + db.execSQL("DROP TABLE PriceAlert") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_36_37.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_36_37.kt index df22b9b96a9..628a3b46a14 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_36_37.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_36_37.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_36_37 : Migration(36, 37) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `EvmAccountState` (`accountId` TEXT NOT NULL, `chainId` INTEGER NOT NULL, `transactionsSyncedBlockNumber` INTEGER NOT NULL, PRIMARY KEY(`accountId`, `chainId`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `EvmAccountState` (`accountId` TEXT NOT NULL, `chainId` INTEGER NOT NULL, `transactionsSyncedBlockNumber` INTEGER NOT NULL, PRIMARY KEY(`accountId`, `chainId`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_37_38.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_37_38.kt index 86fc8ad64e6..45de5c66c0e 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_37_38.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_37_38.kt @@ -4,8 +4,8 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_37_38 : Migration(37, 38) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord` (`accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `totalSupply` INTEGER NOT NULL, `averagePrice7d_coinTypeId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_coinTypeId` TEXT, `averagePrice30d_value` TEXT, `floorPrice_coinTypeId` TEXT, `floorPrice_value` TEXT, `external_url` TEXT, `discord_url` TEXT, `telegram_url` TEXT, `twitter_username` TEXT, `instagram_username` TEXT, `wiki_url` TEXT, PRIMARY KEY(`accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") - database.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetRecord` (`accountId` TEXT NOT NULL, `collectionUid` TEXT NOT NULL, `tokenId` TEXT NOT NULL, `name` TEXT, `imageUrl` TEXT, `imagePreviewUrl` TEXT, `description` TEXT, `onSale` INTEGER NOT NULL, `attributes` TEXT NOT NULL, `coinTypeId` TEXT, `value` TEXT, `contract_address` TEXT NOT NULL, `contract_type` TEXT NOT NULL, `external_link` TEXT, `permalink` TEXT, PRIMARY KEY(`accountId`, `tokenId`, `contract_address`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord` (`accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `totalSupply` INTEGER NOT NULL, `averagePrice7d_coinTypeId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_coinTypeId` TEXT, `averagePrice30d_value` TEXT, `floorPrice_coinTypeId` TEXT, `floorPrice_value` TEXT, `external_url` TEXT, `discord_url` TEXT, `telegram_url` TEXT, `twitter_username` TEXT, `instagram_username` TEXT, `wiki_url` TEXT, PRIMARY KEY(`accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + db.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetRecord` (`accountId` TEXT NOT NULL, `collectionUid` TEXT NOT NULL, `tokenId` TEXT NOT NULL, `name` TEXT, `imageUrl` TEXT, `imagePreviewUrl` TEXT, `description` TEXT, `onSale` INTEGER NOT NULL, `attributes` TEXT NOT NULL, `coinTypeId` TEXT, `value` TEXT, `contract_address` TEXT NOT NULL, `contract_type` TEXT NOT NULL, `external_link` TEXT, `permalink` TEXT, PRIMARY KEY(`accountId`, `tokenId`, `contract_address`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_38_39.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_38_39.kt index a9486040249..13c9f24bc5d 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_38_39.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_38_39.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_38_39 : Migration(38, 39) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `WalletConnectV2Session` (`accountId` TEXT NOT NULL, `topic` TEXT NOT NULL, PRIMARY KEY(`accountId`, `topic`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `WalletConnectV2Session` (`accountId` TEXT NOT NULL, `topic` TEXT NOT NULL, PRIMARY KEY(`accountId`, `topic`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_39_40.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_39_40.kt index efc9e1146e6..dcd305914e1 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_39_40.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_39_40.kt @@ -4,12 +4,12 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_39_40 : Migration(39, 40) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("ALTER TABLE EnabledWallet ADD `coinName` TEXT") - database.execSQL("ALTER TABLE EnabledWallet ADD `coinCode` TEXT") - database.execSQL("ALTER TABLE EnabledWallet ADD `coinDecimals` INTEGER") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("ALTER TABLE EnabledWallet ADD `coinName` TEXT") + db.execSQL("ALTER TABLE EnabledWallet ADD `coinCode` TEXT") + db.execSQL("ALTER TABLE EnabledWallet ADD `coinDecimals` INTEGER") - database.execSQL( + db.execSQL( "UPDATE EnabledWallet " + "SET coinName = (SELECT coinName FROM CustomToken WHERE CustomToken.coinType = EnabledWallet.coinId), " + "coinCode = (SELECT coinCode FROM CustomToken WHERE CustomToken.coinType = EnabledWallet.coinId), " + @@ -17,6 +17,6 @@ object Migration_39_40 : Migration(39, 40) { "WHERE EXISTS (SELECT * FROM CustomToken WHERE CustomToken.coinType = EnabledWallet.coinId)" ) - database.execSQL("DELETE FROM CustomToken") + db.execSQL("DELETE FROM CustomToken") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_40_41.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_40_41.kt index d21455839de..7ec55c35d96 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_40_41.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_40_41.kt @@ -6,11 +6,11 @@ import io.horizontalsystems.bankwallet.core.storage.BlockchainSettingsStorage import io.horizontalsystems.bankwallet.entities.BtcRestoreMode object Migration_40_41 : Migration(40, 41) { - override fun migrate(database: SupportSQLiteDatabase) { + override fun migrate(db: SupportSQLiteDatabase) { val btcRestoreKey = BlockchainSettingsStorage.keyBtcRestore - database.execSQL("CREATE TABLE IF NOT EXISTS `BlockchainSettingRecord` (`blockchainUid` TEXT NOT NULL, `key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`blockchainUid`, `key`))") + db.execSQL("CREATE TABLE IF NOT EXISTS `BlockchainSettingRecord` (`blockchainUid` TEXT NOT NULL, `key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`blockchainUid`, `key`))") - val cursor = database.query("SELECT * FROM BlockchainSetting") + val cursor = db.query("SELECT * FROM BlockchainSetting") while (cursor.moveToNext()) { val coinTypeColumnIndex = cursor.getColumnIndex("coinType") val keyColumnIndex = cursor.getColumnIndex("key") @@ -34,7 +34,7 @@ object Migration_40_41 : Migration(40, 41) { else -> BtcRestoreMode.Hybrid } btcBlockchain?.let { blockchain -> - database.execSQL( + db.execSQL( """ INSERT INTO BlockchainSettingRecord (`blockchainUid`,`key`,`value`) VALUES ('${blockchain.raw}', '$btcRestoreKey', '${btcRestoreMode.raw}') @@ -46,8 +46,8 @@ object Migration_40_41 : Migration(40, 41) { } } - database.execSQL("DROP TABLE BlockchainSetting") - database.execSQL("DROP TABLE AccountSettingRecord") + db.execSQL("DROP TABLE BlockchainSetting") + db.execSQL("DROP TABLE AccountSettingRecord") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_41_42.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_41_42.kt index 95af7b24cec..b9d96f0c5b5 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_41_42.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_41_42.kt @@ -4,8 +4,8 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_41_42 : Migration(41, 42) { - override fun migrate(database: SupportSQLiteDatabase) { + override fun migrate(db: SupportSQLiteDatabase) { //clean LogEntry table from WalletConnect logs - database.execSQL("DELETE FROM LogEntry WHERE actionId LIKE 'WalletConnect%'") + db.execSQL("DELETE FROM LogEntry WHERE actionId LIKE 'WalletConnect%'") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_42_43.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_42_43.kt index 4fe9ad73c4c..857a041e0a9 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_42_43.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_42_43.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_42_43 : Migration(42, 43) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `ProFeaturesSessionKey` (`nftName` TEXT NOT NULL, `accountId` TEXT NOT NULL, `address` TEXT NOT NULL, `key` TEXT NOT NULL, PRIMARY KEY(`nftName`, `accountId`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `ProFeaturesSessionKey` (`nftName` TEXT NOT NULL, `accountId` TEXT NOT NULL, `address` TEXT NOT NULL, `key` TEXT NOT NULL, PRIMARY KEY(`nftName`, `accountId`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_43_44.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_43_44.kt index be218217fd8..a3690b21d52 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_43_44.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_43_44.kt @@ -4,9 +4,9 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_43_44 : Migration(43, 44) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `SyncerState` (`key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`key`))") - database.execSQL("CREATE TABLE IF NOT EXISTS `EvmAddressLabel` (`address` TEXT NOT NULL, `label` TEXT NOT NULL, PRIMARY KEY(`address`))") - database.execSQL("CREATE TABLE IF NOT EXISTS `EvmMethodLabel` (`methodId` TEXT NOT NULL, `label` TEXT NOT NULL, PRIMARY KEY(`methodId`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `SyncerState` (`key` TEXT NOT NULL, `value` TEXT NOT NULL, PRIMARY KEY(`key`))") + db.execSQL("CREATE TABLE IF NOT EXISTS `EvmAddressLabel` (`address` TEXT NOT NULL, `label` TEXT NOT NULL, PRIMARY KEY(`address`))") + db.execSQL("CREATE TABLE IF NOT EXISTS `EvmMethodLabel` (`methodId` TEXT NOT NULL, `label` TEXT NOT NULL, PRIMARY KEY(`methodId`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_44_45.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_44_45.kt index 03b84494d96..2b3ef152770 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_44_45.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_44_45.kt @@ -4,8 +4,8 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_44_45 : Migration(44, 45) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("DROP TABLE IF EXISTS `NftCollectionRecord`") - database.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord` (`accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `totalSupply` INTEGER NOT NULL, `averagePrice7d_coinTypeId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_coinTypeId` TEXT, `averagePrice30d_value` TEXT, `floorPrice_coinTypeId` TEXT, `floorPrice_value` TEXT, `external_url` TEXT, `discord_url` TEXT, `twitter_username` TEXT, PRIMARY KEY(`accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("DROP TABLE IF EXISTS `NftCollectionRecord`") + db.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord` (`accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `totalSupply` INTEGER NOT NULL, `averagePrice7d_coinTypeId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_coinTypeId` TEXT, `averagePrice30d_value` TEXT, `floorPrice_coinTypeId` TEXT, `floorPrice_value` TEXT, `external_url` TEXT, `discord_url` TEXT, `twitter_username` TEXT, PRIMARY KEY(`accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_45_46.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_45_46.kt index 9dc22922b86..5695d5a0a63 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_45_46.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_45_46.kt @@ -9,13 +9,13 @@ import io.horizontalsystems.marketkit.models.TokenType import kotlinx.parcelize.Parcelize object Migration_45_46 : Migration(45, 46) { - override fun migrate(database: SupportSQLiteDatabase) { - renameColumnEnabledWallet(database) - renameColumnEnabledWalletCache(database) - renameColumnRestoreSettingRecord(database) - renameColumnNftCollectionRecord(database) - renameColumnNftAssetRecord(database) - deleteRecordsAppLogMemory(database) + override fun migrate(db: SupportSQLiteDatabase) { + renameColumnEnabledWallet(db) + renameColumnEnabledWalletCache(db) + renameColumnRestoreSettingRecord(db) + renameColumnNftCollectionRecord(db) + renameColumnNftAssetRecord(db) + deleteRecordsAppLogMemory(db) } private fun renameColumnEnabledWallet(database: SupportSQLiteDatabase) { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_46_47.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_46_47.kt index c1bac2051da..c8f152fa560 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_46_47.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_46_47.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_46_47 : Migration(46, 47) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("ALTER TABLE EvmAccountState ADD `restored` INTEGER NOT NULL DEFAULT 0") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("ALTER TABLE EvmAccountState ADD `restored` INTEGER NOT NULL DEFAULT 0") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_47_48.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_47_48.kt index 03e9e05f85c..d76ed88b505 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_47_48.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_47_48.kt @@ -4,16 +4,16 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_47_48 : Migration(47, 48) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord_new` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `averagePrice7d_tokenQueryId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_tokenQueryId` TEXT, `averagePrice30d_value` TEXT, PRIMARY KEY(`blockchainType`, `accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") - database.execSQL("DROP TABLE NftCollectionRecord" ) - database.execSQL("ALTER TABLE NftCollectionRecord_new RENAME TO NftCollectionRecord") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `NftCollectionRecord_new` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `uid` TEXT NOT NULL, `name` TEXT NOT NULL, `imageUrl` TEXT, `averagePrice7d_tokenQueryId` TEXT, `averagePrice7d_value` TEXT, `averagePrice30d_tokenQueryId` TEXT, `averagePrice30d_value` TEXT, PRIMARY KEY(`blockchainType`, `accountId`, `uid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + db.execSQL("DROP TABLE NftCollectionRecord" ) + db.execSQL("ALTER TABLE NftCollectionRecord_new RENAME TO NftCollectionRecord") - database.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetRecord_new` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `nftUid` TEXT NOT NULL, `collectionUid` TEXT NOT NULL, `name` TEXT, `imagePreviewUrl` TEXT, `onSale` INTEGER NOT NULL, `lastSale_tokenQueryId` TEXT, `lastSale_value` TEXT, PRIMARY KEY(`blockchainType`, `accountId`, `nftUid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") - database.execSQL("DROP TABLE NftAssetRecord" ) - database.execSQL("ALTER TABLE NftAssetRecord_new RENAME TO NftAssetRecord") + db.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetRecord_new` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `nftUid` TEXT NOT NULL, `collectionUid` TEXT NOT NULL, `name` TEXT, `imagePreviewUrl` TEXT, `onSale` INTEGER NOT NULL, `lastSale_tokenQueryId` TEXT, `lastSale_value` TEXT, PRIMARY KEY(`blockchainType`, `accountId`, `nftUid`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE NO ACTION ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + db.execSQL("DROP TABLE NftAssetRecord" ) + db.execSQL("ALTER TABLE NftAssetRecord_new RENAME TO NftAssetRecord") - database.execSQL("CREATE TABLE IF NOT EXISTS `NftMetadataSyncRecord` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `lastSyncTimestamp` INTEGER NOT NULL, PRIMARY KEY(`blockchainType`, `accountId`))") + db.execSQL("CREATE TABLE IF NOT EXISTS `NftMetadataSyncRecord` (`blockchainType` TEXT NOT NULL, `accountId` TEXT NOT NULL, `lastSyncTimestamp` INTEGER NOT NULL, PRIMARY KEY(`blockchainType`, `accountId`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_48_49.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_48_49.kt index 1a055ea4f84..b8f1a462a03 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_48_49.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_48_49.kt @@ -4,6 +4,6 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_48_49 : Migration(48, 49) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetBriefMetadataRecord` (`nftUid` TEXT NOT NULL, `providerCollectionUid` TEXT NOT NULL, `name` TEXT, `imageUrl` TEXT, `previewImageUrl` TEXT, PRIMARY KEY(`nftUid`))") } + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `NftAssetBriefMetadataRecord` (`nftUid` TEXT NOT NULL, `providerCollectionUid` TEXT NOT NULL, `name` TEXT, `imageUrl` TEXT, `previewImageUrl` TEXT, PRIMARY KEY(`nftUid`))") } } \ No newline at end of file diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_49_50.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_49_50.kt index 9924352f5ae..5301f8821c8 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_49_50.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_49_50.kt @@ -4,6 +4,6 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_49_50 : Migration(49, 50) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `EvmSyncSourceRecord` (`url` TEXT NOT NULL, `blockchainTypeUid` TEXT NOT NULL, `auth` TEXT, PRIMARY KEY(`blockchainTypeUid`,`url`))") } + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `EvmSyncSourceRecord` (`url` TEXT NOT NULL, `blockchainTypeUid` TEXT NOT NULL, `auth` TEXT, PRIMARY KEY(`blockchainTypeUid`,`url`))") } } \ No newline at end of file diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_50_51.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_50_51.kt index a7ef370605d..e225e90f0b3 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_50_51.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_50_51.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_50_51 : Migration(50, 51) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("ALTER TABLE AccountRecord ADD `isFileBackedUp` INTEGER NOT NULL DEFAULT 0") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("ALTER TABLE AccountRecord ADD `isFileBackedUp` INTEGER NOT NULL DEFAULT 0") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_51_52.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_51_52.kt index 8c83e5dfd31..0ab280439cc 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_51_52.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_51_52.kt @@ -4,8 +4,8 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_51_52 : Migration(51, 52) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("DROP TABLE IF EXISTS `EvmAccountState`") - database.execSQL("CREATE TABLE IF NOT EXISTS `TokenAutoEnabledBlockchain` (`accountId` TEXT NOT NULL, `blockchainType` TEXT NOT NULL, PRIMARY KEY(`accountId`, `blockchainType`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("DROP TABLE IF EXISTS `EvmAccountState`") + db.execSQL("CREATE TABLE IF NOT EXISTS `TokenAutoEnabledBlockchain` (`accountId` TEXT NOT NULL, `blockchainType` TEXT NOT NULL, PRIMARY KEY(`accountId`, `blockchainType`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_52_53.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_52_53.kt index 5ad25bee8e3..1667e1f1726 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_52_53.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_52_53.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_52_53 : Migration(52, 53) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `CexAssetRaw` (`id` TEXT NOT NULL, `accountId` TEXT NOT NULL, `name` TEXT NOT NULL, `freeBalance` TEXT NOT NULL, `lockedBalance` TEXT NOT NULL, `depositEnabled` INTEGER NOT NULL, `withdrawEnabled` INTEGER NOT NULL, `depositNetworks` TEXT NOT NULL, `withdrawNetworks` TEXT NOT NULL, `coinUid` TEXT, `decimals` INTEGER NOT NULL, PRIMARY KEY(`id`, `accountId`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `CexAssetRaw` (`id` TEXT NOT NULL, `accountId` TEXT NOT NULL, `name` TEXT NOT NULL, `freeBalance` TEXT NOT NULL, `lockedBalance` TEXT NOT NULL, `depositEnabled` INTEGER NOT NULL, `withdrawEnabled` INTEGER NOT NULL, `depositNetworks` TEXT NOT NULL, `withdrawNetworks` TEXT NOT NULL, `coinUid` TEXT, `decimals` INTEGER NOT NULL, PRIMARY KEY(`id`, `accountId`))") } } \ No newline at end of file diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_53_54.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_53_54.kt index dac79e23771..50adc16acd4 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_53_54.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_53_54.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_53_54 : Migration(53, 54) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `ChartIndicatorSetting` (`id` TEXT NOT NULL, `type` TEXT NOT NULL, `index` INTEGER NOT NULL, `extraData` TEXT NOT NULL, `defaultData` TEXT NOT NULL, `enabled` INTEGER NOT NULL, PRIMARY KEY(`id`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `ChartIndicatorSetting` (`id` TEXT NOT NULL, `type` TEXT NOT NULL, `index` INTEGER NOT NULL, `extraData` TEXT NOT NULL, `defaultData` TEXT NOT NULL, `enabled` INTEGER NOT NULL, PRIMARY KEY(`id`))") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_54_55.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_54_55.kt index 9793e5c5ef9..518c35c26ab 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_54_55.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_54_55.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_54_55 : Migration(54, 55) { - override fun migrate(database: SupportSQLiteDatabase) { + override fun migrate(db: SupportSQLiteDatabase) { val derivations = listOf("bip44", "bip49", "bip84", "bip86") val blockchainTypes = listOf("bitcoin", "litecoin") @@ -14,7 +14,7 @@ object Migration_54_55 : Migration(54, 55) { val coinSettingsId = "derivation:$derivation" val newTokenQueryId = "$blockchainTypeId|derived:${derivation.replaceFirstChar(Char::titlecase)}" - database.execSQL("UPDATE `EnabledWallet` SET tokenQueryId = '$newTokenQueryId' WHERE tokenQueryId = '$tokenQueryId' AND coinSettingsId = '$coinSettingsId'") + db.execSQL("UPDATE `EnabledWallet` SET tokenQueryId = '$newTokenQueryId' WHERE tokenQueryId = '$tokenQueryId' AND coinSettingsId = '$coinSettingsId'") } } @@ -24,19 +24,19 @@ object Migration_54_55 : Migration(54, 55) { val coinSettingsId = "bitcoinCashCoinType:$bchType" val newTokenQueryId = "bitcoin-cash|address_type:${bchType.replaceFirstChar(Char::titlecase)}" - database.execSQL("UPDATE `EnabledWallet` SET tokenQueryId = '$newTokenQueryId' WHERE tokenQueryId = '$tokenQueryId' AND coinSettingsId = '$coinSettingsId'") + db.execSQL("UPDATE `EnabledWallet` SET tokenQueryId = '$newTokenQueryId' WHERE tokenQueryId = '$tokenQueryId' AND coinSettingsId = '$coinSettingsId'") } - database.execSQL("ALTER TABLE EnabledWallet RENAME TO TempEnabledWallet") - database.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWallet` (`tokenQueryId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `walletOrder` INTEGER, `coinName` TEXT, `coinCode` TEXT, `coinDecimals` INTEGER, PRIMARY KEY(`tokenQueryId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") - database.execSQL("INSERT INTO `EnabledWallet`(tokenQueryId, accountId, walletOrder, coinName, coinCode, coinDecimals) SELECT tokenQueryId, accountId, walletOrder, coinName, coinCode, coinDecimals FROM `TempEnabledWallet`") - database.execSQL("DROP TABLE IF EXISTS `TempEnabledWallet`") - database.execSQL("CREATE INDEX IF NOT EXISTS `index_EnabledWallet_accountId` ON `EnabledWallet` (`accountId`)") + db.execSQL("ALTER TABLE EnabledWallet RENAME TO TempEnabledWallet") + db.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWallet` (`tokenQueryId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `walletOrder` INTEGER, `coinName` TEXT, `coinCode` TEXT, `coinDecimals` INTEGER, PRIMARY KEY(`tokenQueryId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + db.execSQL("INSERT INTO `EnabledWallet`(tokenQueryId, accountId, walletOrder, coinName, coinCode, coinDecimals) SELECT tokenQueryId, accountId, walletOrder, coinName, coinCode, coinDecimals FROM `TempEnabledWallet`") + db.execSQL("DROP TABLE IF EXISTS `TempEnabledWallet`") + db.execSQL("CREATE INDEX IF NOT EXISTS `index_EnabledWallet_accountId` ON `EnabledWallet` (`accountId`)") - database.execSQL("DROP TABLE IF EXISTS `EnabledWalletCache`") - database.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWalletCache` (`tokenQueryId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `balance` TEXT NOT NULL, `balanceLocked` TEXT NOT NULL, PRIMARY KEY(`tokenQueryId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") + db.execSQL("DROP TABLE IF EXISTS `EnabledWalletCache`") + db.execSQL("CREATE TABLE IF NOT EXISTS `EnabledWalletCache` (`tokenQueryId` TEXT NOT NULL, `accountId` TEXT NOT NULL, `balance` TEXT NOT NULL, `balanceLocked` TEXT NOT NULL, PRIMARY KEY(`tokenQueryId`, `accountId`), FOREIGN KEY(`accountId`) REFERENCES `AccountRecord`(`id`) ON UPDATE CASCADE ON DELETE CASCADE DEFERRABLE INITIALLY DEFERRED)") } } \ No newline at end of file diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_55_56.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_55_56.kt index 11b6a629a0d..dd3993ef410 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_55_56.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_55_56.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_55_56 : Migration(55, 56) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("DROP TABLE IF EXISTS WalletConnectSession") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("DROP TABLE IF EXISTS WalletConnectSession") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_56_57.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_56_57.kt index b9dec55e737..6d41adce5ff 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_56_57.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_56_57.kt @@ -5,12 +5,12 @@ import androidx.sqlite.db.SupportSQLiteDatabase import io.horizontalsystems.bankwallet.core.App object Migration_56_57 : Migration(56, 57) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("ALTER TABLE AccountRecord ADD `level` INTEGER NOT NULL DEFAULT 0") - database.execSQL("CREATE TABLE IF NOT EXISTS `Pin` (`level` INTEGER NOT NULL, `passcode` TEXT, PRIMARY KEY(`level`))") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("ALTER TABLE AccountRecord ADD `level` INTEGER NOT NULL DEFAULT 0") + db.execSQL("CREATE TABLE IF NOT EXISTS `Pin` (`level` INTEGER NOT NULL, `passcode` TEXT, PRIMARY KEY(`level`))") App.pinSettingsStorage.pin?.let { - database.execSQL("INSERT INTO `Pin` VALUES(0, ?)", arrayOf(it)) + db.execSQL("INSERT INTO `Pin` VALUES(0, ?)", arrayOf(it)) } } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_57_58.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_57_58.kt index 20721d75383..a3772f1b61d 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_57_58.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_57_58.kt @@ -4,10 +4,10 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_57_58 : Migration(57, 58) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE `ActiveAccount_new` (`level` INTEGER NOT NULL, `accountId` TEXT NOT NULL, PRIMARY KEY(`level`))") - database.execSQL("INSERT INTO ActiveAccount_new (`accountId`, `level`) SELECT `accountId`, 0 FROM ActiveAccount LIMIT 0, 1") - database.execSQL("DROP TABLE ActiveAccount") - database.execSQL("ALTER TABLE ActiveAccount_new RENAME TO ActiveAccount") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE `ActiveAccount_new` (`level` INTEGER NOT NULL, `accountId` TEXT NOT NULL, PRIMARY KEY(`level`))") + db.execSQL("INSERT INTO ActiveAccount_new (`accountId`, `level`) SELECT `accountId`, 0 FROM ActiveAccount LIMIT 0, 1") + db.execSQL("DROP TABLE ActiveAccount") + db.execSQL("ALTER TABLE ActiveAccount_new RENAME TO ActiveAccount") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_58_59.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_58_59.kt index 36147e28c22..2db92a7ae33 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_58_59.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/storage/migrations/Migration_58_59.kt @@ -4,7 +4,7 @@ import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase object Migration_58_59 : Migration(58, 59) { - override fun migrate(database: SupportSQLiteDatabase) { - database.execSQL("CREATE TABLE IF NOT EXISTS `StatRecord` (`json` TEXT NOT NULL, `id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL)") + override fun migrate(db: SupportSQLiteDatabase) { + db.execSQL("CREATE TABLE IF NOT EXISTS `StatRecord` (`json` TEXT NOT NULL, `id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL)") } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/Tor.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/Tor.kt index d94dca8bcd1..cb324a39065 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/Tor.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/Tor.kt @@ -34,7 +34,7 @@ enum class ConnectionStatus { fun getByName(typName: String): ConnectionStatus { return values() - .find { it.name.contentEquals(typName.toUpperCase()) } ?: CLOSED + .find { it.name.contentEquals(typName.uppercase()) } ?: CLOSED } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorOperator.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorOperator.kt index 36fb3a52211..1a967e5a2c6 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorOperator.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorOperator.kt @@ -162,7 +162,7 @@ class TorOperator(private val torSettings: Tor.Settings, private val listener: L var exitCode: Int exitCode = try { - exec("$torCmdString --verify-config", true) + exec("$torCmdString --verify-config") } catch (e: Exception) { eventMonitor(msg = "Tor configuration did not verify: " + e.message + e) return false @@ -174,7 +174,7 @@ class TorOperator(private val torSettings: Tor.Settings, private val listener: L } exitCode = try { - exec(torCmdString, true) + exec(torCmdString) } catch (e: Exception) { eventMonitor(msg = "Tor was unable to start: " + e.message + e) return false @@ -189,7 +189,7 @@ class TorOperator(private val torSettings: Tor.Settings, private val listener: L } @Throws(Exception::class) - private fun exec(cmd: String, wait: Boolean = false): Int { + private fun exec(cmd: String): Int { val shellResult = Shell.run(cmd) // debug("CMD: " + cmd + "; SUCCESS=" + shellResult.isSuccessful()); diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorResourceManager.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorResourceManager.kt index 2714ede3231..d43901a3fb1 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorResourceManager.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torcore/TorResourceManager.kt @@ -111,7 +111,7 @@ class TorResourceManager(private val torSettings: Tor.Settings) { private fun checkPortOrAuto(portString: String): String { - if (!portString.toLowerCase().contentEquals("auto")) { + if (!portString.lowercase().contentEquals("auto")) { var isPortUsed = true var port = portString.toInt() diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/CoreUtils.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/CoreUtils.kt index 97fd18413db..346118a6b36 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/CoreUtils.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/CoreUtils.kt @@ -53,7 +53,7 @@ object ProcessUtils { @Throws(Exception::class) fun killProcess(fileProcBin: File, signal: String) { - var procId = -1 + var procId: Int var killAttempts = 0 while (findProcessId(fileProcBin.name).also { procId = it } != -1) { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/NativeLoader.kt b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/NativeLoader.kt index 4e09e774e9d..2ce388dbaf3 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/NativeLoader.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/core/tor/torutils/NativeLoader.kt @@ -90,7 +90,7 @@ object NativeLoader { return fileNativeBin } } - var folder = Build.CPU_ABI + var folder = Build.SUPPORTED_ABIS[0] val javaArch = System.getProperty("os.arch") if (javaArch != null && javaArch.contains("686")) { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/coin/analytics/ui/Components.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/coin/analytics/ui/Components.kt index d8d22333387..53dc5a0a468 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/coin/analytics/ui/Components.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/coin/analytics/ui/Components.kt @@ -27,7 +27,6 @@ import androidx.compose.ui.tooling.preview.Preview import androidx.compose.ui.unit.dp import androidx.compose.ui.viewinterop.AndroidView import androidx.core.view.doOnLayout -import androidx.navigation.compose.rememberNavController import io.horizontalsystems.bankwallet.R import io.horizontalsystems.bankwallet.modules.coin.analytics.CoinAnalyticsModule import io.horizontalsystems.bankwallet.modules.coin.analytics.CoinAnalyticsModule.BoxItem @@ -368,7 +367,6 @@ private fun Preview_HoldersBlockLocked() { @Preview @Composable private fun Preview_AnalyticsBarChartDisabled() { - val navController = rememberNavController() ComposeAppTheme { AnalyticsContainer( titleRow = { @@ -401,7 +399,6 @@ private fun Preview_AnalyticsBarChartDisabled() { @Preview @Composable private fun Preview_AnalyticsLineChartDisabled() { - val navController = rememberNavController() ComposeAppTheme { AnalyticsContainer( titleRow = { @@ -479,7 +476,6 @@ private fun Preview_HoldersBlock() { @Preview @Composable private fun Preview_AnalyticsRatingScale() { - val navController = rememberNavController() ComposeAppTheme { AnalyticsContainer( titleRow = { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/ContactsModule.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/ContactsModule.kt index 5d3b40d854e..4ed50bacafa 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/ContactsModule.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/ContactsModule.kt @@ -43,7 +43,6 @@ object ContactsModule { contactUid, App.contactsRepository, AddressHandlerFactory(App.appConfigProvider.udnApiKey), - App.evmBlockchainManager, App.marketKit, contactAddress, definedAddresses diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/viewmodel/AddressViewModel.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/viewmodel/AddressViewModel.kt index 925db3c8283..b863e15edcf 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/viewmodel/AddressViewModel.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/contacts/viewmodel/AddressViewModel.kt @@ -27,7 +27,6 @@ class AddressViewModel( private val contactUid: String?, private val contactsRepository: ContactsRepository, private val addressHandlerFactory: AddressHandlerFactory, - evmBlockchainManager: EvmBlockchainManager, marketKit: MarketKitWrapper, contactAddress: ContactAddress?, definedAddresses: List? diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountEnterCexDataScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountEnterCexDataScreen.kt index 20694159c34..c7a1bb0535d 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountEnterCexDataScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountEnterCexDataScreen.kt @@ -41,7 +41,6 @@ fun ImportCexAccountEnterCexDataScreen( onNavigateBack: () -> Unit, onClose: () -> Unit, onAccountCreate: () -> Unit, - onShowError: (title: TranslatableString, description: TranslatableString) -> Unit, ) { val viewModel = viewModel(factory = ImportCexAccountEnterCexDataViewModel.Factory(cexId)) diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountFragment.kt index a581fd0cc1c..2407196201a 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/importcexaccount/ImportCexAccountFragment.kt @@ -10,8 +10,6 @@ import io.horizontalsystems.bankwallet.R import io.horizontalsystems.bankwallet.core.BaseComposeFragment import io.horizontalsystems.bankwallet.core.composablePage import io.horizontalsystems.bankwallet.core.getInput -import io.horizontalsystems.bankwallet.core.slideFromBottom -import io.horizontalsystems.bankwallet.modules.info.ErrorDisplayDialogFragment import io.horizontalsystems.bankwallet.modules.manageaccounts.ManageAccountsModule import io.horizontalsystems.core.helpers.HudHelper @@ -61,12 +59,6 @@ fun ImportCexAccountNavHost( iconTint = R.color.white ) fragmentNavController.popBackStack(popUpToInclusiveId, inclusive) - }, - onShowError = { title, text -> - fragmentNavController.slideFromBottom( - R.id.errorDisplayDialogFragment, - ErrorDisplayDialogFragment.Input(title.toString(), text.toString()) - ) } ) } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/manageaccount/dialogs/BackupRequiredDialog.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/manageaccount/dialogs/BackupRequiredDialog.kt index 417a1172771..e3798e53600 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/manageaccount/dialogs/BackupRequiredDialog.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/manageaccount/dialogs/BackupRequiredDialog.kt @@ -48,7 +48,7 @@ class BackupRequiredDialog : BaseComposableBottomSheetFragment() { setContent { val navController = findNavController() navController.getInput()?.let { input -> - BackupRequiredScreen(navController, input.account, input.text ?: "") + BackupRequiredScreen(navController, input.account, input.text) } } } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopCoinsService.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopCoinsService.kt index 5dd235a19e4..5b03a81477b 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopCoinsService.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopCoinsService.kt @@ -59,8 +59,7 @@ class MarketTopCoinsService( topMarket.value, sortingField, topMarket.value, - currencyManager.baseCurrency, - marketField + currencyManager.baseCurrency ).await() syncItems() diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopMoversRepository.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopMoversRepository.kt index c3104160af0..06c6eac3220 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopMoversRepository.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topcoins/MarketTopMoversRepository.kt @@ -2,7 +2,6 @@ package io.horizontalsystems.bankwallet.modules.market.topcoins import io.horizontalsystems.bankwallet.core.managers.MarketKitWrapper import io.horizontalsystems.bankwallet.entities.Currency -import io.horizontalsystems.bankwallet.modules.market.MarketField import io.horizontalsystems.bankwallet.modules.market.MarketItem import io.horizontalsystems.bankwallet.modules.market.SortingField import io.horizontalsystems.bankwallet.modules.market.sort @@ -21,8 +20,7 @@ class MarketTopMoversRepository( size: Int, sortingField: SortingField, limit: Int, - baseCurrency: Currency, - marketField: MarketField + baseCurrency: Currency ): Single> = Single.create { emitter -> try { diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topplatforms/TopPlatformsFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topplatforms/TopPlatformsFragment.kt index df9c2324d94..6fe21120469 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topplatforms/TopPlatformsFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/market/topplatforms/TopPlatformsFragment.kt @@ -2,7 +2,6 @@ package io.horizontalsystems.bankwallet.modules.market.topplatforms import androidx.compose.animation.Crossfade import androidx.compose.foundation.ExperimentalFoundationApi -import androidx.compose.foundation.interaction.MutableInteractionSource import androidx.compose.foundation.layout.Column import androidx.compose.foundation.layout.Row import androidx.compose.foundation.layout.Spacer @@ -86,8 +85,6 @@ fun TopPlatformsScreen( navController: NavController, ) { - val interactionSource = remember { MutableInteractionSource() } - Surface(color = ComposeAppTheme.colors.tyler) { Column { TopCloseButton { navController.popBackStack() } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip1155Screen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip1155Screen.kt index 39d13dabbdd..ea2c57705de 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip1155Screen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip1155Screen.kt @@ -58,7 +58,6 @@ fun SendEip1155Screen( viewModel: SendEip1155ViewModel, addressViewModel: AddressViewModel, addressParserViewModel: AddressParserViewModel, - nftSendFragment: Int, ) { Scaffold( diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip721Screen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip721Screen.kt index 4f37d76bf78..67fcbaaf8eb 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip721Screen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendEip721Screen.kt @@ -38,7 +38,6 @@ fun SendEip721Screen( viewModel: SendEip721ViewModel, addressViewModel: AddressViewModel, addressParserViewModel: AddressParserViewModel, - parentNavId: Int, ) { Scaffold( diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendNftFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendNftFragment.kt index 7b0af57e8d5..f98acae8cc5 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendNftFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/nft/send/SendNftFragment.kt @@ -49,7 +49,6 @@ class SendNftFragment : BaseComposeFragment() { eip721ViewModel, addressViewModel, addressParserViewModel, - R.id.nftSendFragment, ) } @@ -64,7 +63,6 @@ class SendNftFragment : BaseComposeFragment() { eip1155ViewModel, addressViewModel, addressParserViewModel, - R.id.nftSendFragment, ) } diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/SendConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/SendConfirmationScreen.kt index 92442e0f77c..d368417e3b2 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/SendConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/SendConfirmationScreen.kt @@ -64,7 +64,6 @@ fun SendConfirmationScreen( navController: NavController, coinMaxAllowedDecimals: Int, feeCoinMaxAllowedDecimals: Int, - fiatMaxAllowedDecimals: Int, amountInputType: AmountInputType, rate: CurrencyValue?, feeCoinRate: CurrencyValue?, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/binance/SendBinanceConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/binance/SendBinanceConfirmationScreen.kt index 55f96c349d3..5336b5d8c90 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/binance/SendBinanceConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/binance/SendBinanceConfirmationScreen.kt @@ -34,7 +34,6 @@ fun SendBinanceConfirmationScreen( navController = navController, coinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, feeCoinMaxAllowedDecimals = sendViewModel.feeTokenMaxAllowedDecimals, - fiatMaxAllowedDecimals = sendViewModel.fiatMaxAllowedDecimals, amountInputType = amountInputModeViewModel.inputType, rate = sendViewModel.coinRate, feeCoinRate = sendViewModel.feeCoinRate, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinConfirmationScreen.kt index 68e21e5eadb..d814e41bb57 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinConfirmationScreen.kt @@ -34,7 +34,6 @@ fun SendBitcoinConfirmationScreen( navController = navController, coinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, feeCoinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, - fiatMaxAllowedDecimals = sendViewModel.fiatMaxAllowedDecimals, amountInputType = amountInputModeViewModel.inputType, rate = sendViewModel.coinRate, feeCoinRate = sendViewModel.coinRate, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinScreen.kt index 90948a28e5b..1cdddf6e74b 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinScreen.kt @@ -76,7 +76,7 @@ fun SendBitcoinNavHost( navController = navController, startDestination = SendBtcPage, ) { - composable(SendBtcPage) { entry -> + composable(SendBtcPage) { SendBitcoinScreen( title, fragmentNavController, @@ -96,7 +96,7 @@ fun SendBitcoinNavHost( ) } composablePopup(TransactionInputsSortInfoPage) { BtcTransactionInputSortInfoScreen { navController.popBackStack() } } - composablePage(UtxoExpertModePage) { entry -> + composablePage(UtxoExpertModePage) { UtxoExpertModeScreen( adapter = viewModel.adapter, token = viewModel.wallet.token, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinViewModel.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinViewModel.kt index 7744e83033a..bdcba102ca6 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinViewModel.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/bitcoin/SendBitcoinViewModel.kt @@ -124,8 +124,8 @@ class SendBitcoinViewModel( addressService.setAddress(address) } - fun onEnterMemo(memo: String) { - val memo = memo.ifBlank { null } + fun onEnterMemo(memoValue: String) { + val memo = memoValue.ifBlank { null } this.memo = memo diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/solana/SendSolanaConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/solana/SendSolanaConfirmationScreen.kt index 024c2003b5e..9febbcdc900 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/solana/SendSolanaConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/solana/SendSolanaConfirmationScreen.kt @@ -34,7 +34,6 @@ fun SendSolanaConfirmationScreen( navController = navController, coinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, feeCoinMaxAllowedDecimals = sendViewModel.feeTokenMaxAllowedDecimals, - fiatMaxAllowedDecimals = sendViewModel.fiatMaxAllowedDecimals, amountInputType = amountInputModeViewModel.inputType, rate = sendViewModel.coinRate, feeCoinRate = sendViewModel.feeCoinRate, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/ton/SendTonConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/ton/SendTonConfirmationScreen.kt index 8acf1b3f4ec..b349968646d 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/ton/SendTonConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/ton/SendTonConfirmationScreen.kt @@ -34,7 +34,6 @@ fun SendTonConfirmationScreen( navController = navController, coinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, feeCoinMaxAllowedDecimals = sendViewModel.feeTokenMaxAllowedDecimals, - fiatMaxAllowedDecimals = sendViewModel.fiatMaxAllowedDecimals, amountInputType = amountInputModeViewModel.inputType, rate = sendViewModel.coinRate, feeCoinRate = sendViewModel.feeCoinRate, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/zcash/SendZCashConfirmationScreen.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/zcash/SendZCashConfirmationScreen.kt index cb13653e44c..1d514caf898 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/zcash/SendZCashConfirmationScreen.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/send/zcash/SendZCashConfirmationScreen.kt @@ -34,7 +34,6 @@ fun SendZCashConfirmationScreen( navController = navController, coinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, feeCoinMaxAllowedDecimals = sendViewModel.coinMaxAllowedDecimals, - fiatMaxAllowedDecimals = sendViewModel.fiatMaxAllowedDecimals, amountInputType = amountInputModeViewModel.inputType, rate = sendViewModel.coinRate, feeCoinRate = sendViewModel.coinRate, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/sendtokenselect/SendTokenSelectFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/sendtokenselect/SendTokenSelectFragment.kt index 3d435eee6a7..a83cff866b4 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/sendtokenselect/SendTokenSelectFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/sendtokenselect/SendTokenSelectFragment.kt @@ -54,7 +54,7 @@ class SendTokenSelectFragment : BaseComposeFragment() { } it.errorMessage != null -> { - HudHelper.showErrorMessage(view, it.errorMessage ?: "") + HudHelper.showErrorMessage(view, it.errorMessage) } } }, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/settings/about/AboutFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/settings/about/AboutFragment.kt index 73e219b6815..c774e147403 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/settings/about/AboutFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/settings/about/AboutFragment.kt @@ -105,7 +105,7 @@ private fun AboutScreen( Spacer(Modifier.height(24.dp)) InfoTextBody(text = stringResource(R.string.SettingsTerms_Text)) Spacer(Modifier.height(24.dp)) - SettingSections(aboutViewModel, navController, showContactOptions) + SettingSections(aboutViewModel, navController) Spacer(Modifier.height(36.dp)) } } @@ -115,8 +115,7 @@ private fun AboutScreen( @Composable private fun SettingSections( viewModel: AboutViewModel, - navController: NavController, - showContactOptions: () -> Unit + navController: NavController ) { val context = LocalContext.current diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionViewItemFactory.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionViewItemFactory.kt index 423291b29cc..22351df52e7 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionViewItemFactory.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionViewItemFactory.kt @@ -430,8 +430,6 @@ class TransactionViewItemFactory( is TonTransactionRecord -> { createViewItemFromTonTransactionRecord( - uid = record.uid, - timestamp = record.timestamp, icon = icon, record = record, currencyValue = transactionItem.currencyValue @@ -443,8 +441,6 @@ class TransactionViewItemFactory( } private fun createViewItemFromTonTransactionRecord( - uid: String, - timestamp: Long, icon: TransactionViewItem.Icon?, record: TonTransactionRecord, currencyValue: CurrencyValue?, diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionsFilterFragment.kt b/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionsFilterFragment.kt index bef55d1afff..1ce334bf542 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionsFilterFragment.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/modules/transactions/TransactionsFilterFragment.kt @@ -208,7 +208,7 @@ private fun FilterDropdownCell( verticalAlignment = Alignment.CenterVertically ) { Text( - text = value ?: stringResource(R.string.Any), + text = value, maxLines = 1, style = ComposeAppTheme.typography.body, color = valueColor diff --git a/app/src/main/java/io/horizontalsystems/bankwallet/widgets/MarketWidgetManager.kt b/app/src/main/java/io/horizontalsystems/bankwallet/widgets/MarketWidgetManager.kt index 12fd435a7d4..dcfdfc9b974 100644 --- a/app/src/main/java/io/horizontalsystems/bankwallet/widgets/MarketWidgetManager.kt +++ b/app/src/main/java/io/horizontalsystems/bankwallet/widgets/MarketWidgetManager.kt @@ -104,7 +104,7 @@ class MarketWidgetManager { } } - val localPath = context.imageLoader.diskCache?.get(url)?.use { snapshot -> + val localPath = context.imageLoader.diskCache?.openSnapshot(url)?.use { snapshot -> snapshot.data.toFile().path } diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 339b16173cf..2edb76338bc 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -2,7 +2,7 @@ Parameter ist nicht festgelegt - %s%s + %1$s%2$s Abbrechen Kopieren Schließen @@ -305,8 +305,6 @@ Transaktionen werden gesucht… %s tx Synchronisiere... %s%% - Coins hinzufügen - Coin hinzufügen Deaktivierte Münze %s Guthaben Sortieren nach @@ -315,7 +313,6 @@ verborgen Blöcke herunterladen Scanne Blöcke - Sie müssen ein Backup des %s Wallet machen, bevor Sie %s erhalten können. Sie haben noch keine installierten Wallets.\nErstellen Sie eine neue Wallet oder stellen Sie eine vorhandene wieder her Sie haben keine Coins zu diesem Wallet hinzugefügt. Diese Wallet-Adresse hat keinen Kontostand @@ -393,10 +390,6 @@ Sich selbst zu senden wird nicht unterstützt Verfügbares Guthaben Transaktionsgeschwindigkeit - Niedrig - Hoch - Empfohlen - Benutzerdefiniert Gebühr: Weiter Aus @@ -406,7 +399,7 @@ 1 Jahr Wird gesendet Gebührenrate - Transaktionsgebühren für %s (%s) in %s bezahlt. Du brauchst %s. + Transaktionsgebühren für %1$s (%2$s) in %3$s bezahlt. Du brauchst %4$s. Warnung! Gefahr des Festklemmens Gebührenfehler Die Gebühr ist zu niedrig. @@ -610,7 +603,6 @@ Übernehmen %s Min Adresse oder Domäne - Eine Service-Gebühr für die Swap-Aktion auf der Plattform typischerweise entweder 0,3% oder 0,6% Null Frist Null Slippage Ihre Transaktion wird wahrscheinlich fehlschlagen. diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index 12ce80294a6..b3915d7dfaf 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -2,7 +2,7 @@ Parámetro no establecido - %s%s + %1$s%2$s Cancelar Copiar Cerrar @@ -304,8 +304,6 @@ Buscando transacciones… %s tx Sincronizando... %s%% - Añadir Monedas - Añadir Monedas Moneda deshabilitada %s Saldo Ordenar por @@ -314,7 +312,6 @@ oculto Descargando bloques Bloques de escaneo - Necesita respaldar el monedero %s antes de poder recibir %s. Aún no tiene ninguna cartera instalada.\nCrear una nueva cartera o restaurar una existente No has añadido ninguna moneda a esta cartera. Esta dirección de billetera no tiene saldo @@ -392,10 +389,6 @@ Enviarte a vos mismo no está soportado Saldo disponible Velocidad de transacción - Bajo - Alto - Recomendado - Personalizado Comisión: Siguiente Desactivado @@ -405,7 +398,7 @@ 1 año Enviando Tasa de comisión - Las comisiones de transacción para %s (%s) pagado en %s. Es necesario %s. + Las comisiones de transacción para %1$s (%2$s) pagado en %3$s. Es necesario %4$s. ¡Advertencia! Riesgo de atascarse Error de tarifa La tarifa es demasiado baja. @@ -609,7 +602,6 @@ Aplicar %s min Dominio o dirección - Una tarifa de servicio para la acción de intercambio en la plataforma típicamente de 0,3% o 0,6% Cero límite Cero deslizamiento Es probable que su transacción falle. diff --git a/app/src/main/res/values-fa/strings.xml b/app/src/main/res/values-fa/strings.xml index 17e41981555..b3bbdaeab6e 100644 --- a/app/src/main/res/values-fa/strings.xml +++ b/app/src/main/res/values-fa/strings.xml @@ -1,7 +1,7 @@ - %s%s + %1$s%2$s انصراف رونوشت بستن @@ -132,15 +132,12 @@ همزمانی… در جستجوی تراکنش ها… همزمانی... %%%s - اضافه کردن سکه ها - اضافه کردن سکه ها سکه %s غیرفعال شد مانده حساب مرتب‌ کردن بر اساس نام تغییر قیمت پنهان - قبل از اینکه %s را دریافت کنید به نسخه پشتیبان از کیف پول %s نیاز دارید. این آدرس کیف پول موجودی ندارد نام سکه @@ -175,10 +172,6 @@ ارسال به خود پشتیبانی نشده است موجودی در دسترس سرعت تراکنش - پایین - بالا - توصیه شده - شخصی سازی قیمت: بعدي خاموش diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 2029d8dbaf4..5015c1dbdc7 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -2,7 +2,7 @@ Le paramètre n\'est pas défini - %s%s + %1$s%2$s Annuler Copier Fermer @@ -304,8 +304,6 @@ Recherche des transactions… %s TX Synchronisation... %s%% - Ajouter des coins - Ajouter la pièce Pièce %s désactivée Solde Trier par @@ -314,7 +312,6 @@ masqué Téléchargement des blocs Blocs de numérisation - Vous devez sauvegarder le portefeuille %1$s avant de recevoir %2$s. Vous n\'avez pas encore de portefeuilles installés.\nCréez un nouveau portefeuille ou restaurez un portefeuille existant Vous n\'avez ajouté aucune pièce à ce portefeuille. Cette adresse de portefeuille n\'a pas de solde @@ -392,10 +389,6 @@ L\'envoi à soi-même n\'est pas pris en charge Solde disponible Vitesse de transaction - Faible - Élevée - Recommandé - Personnalisé Frais Suivant Désactivé @@ -609,7 +602,6 @@ Appliquer %s min Adresse ou domaine - Des frais de service pour l\'action de swap sur la plateforme sont typiques de 0,3% ou 0,6% Délai Zéro Zéro Slippage Votre transaction est susceptible de ne pas aboutir. diff --git a/app/src/main/res/values-ko/strings.xml b/app/src/main/res/values-ko/strings.xml index c7cd46e78b5..e879f52ea20 100644 --- a/app/src/main/res/values-ko/strings.xml +++ b/app/src/main/res/values-ko/strings.xml @@ -2,7 +2,7 @@ 매개 변수가 설정되지 않았습니다 - %s%s + %1$s%2$s 취소 복사 가까운, 닫힌 @@ -303,8 +303,6 @@ 거래 검색 중... %s tx 동기화 중입니다...%s%% - 코인 추가 - 코인 추가 비활성화된 코인 %s 잔액 정렬 기준 @@ -313,7 +311,6 @@ 숨겨짐 블록 다운로드 스캐닝 블록 - 귀하께서 %s를 받기전에 %s 지갑의 백업이 필요합니다. 아직 지갑이 없습니다 이 지갑에 코인을 넣지 않았습니다. 이 지갑 주소에는 잔액이 없습니다 @@ -391,10 +388,6 @@ 자체로 전송이 지원되지 않음 사용 가능한 잔액 거래 속도 - 낮음 - 높음 - 권장 - 사용자 지정 수수료: 다음 끄기 @@ -404,7 +397,7 @@ 1 년 전송중 수수료율 - %s (%s) 에 대한 거래 수수료는 %s로 지불되었습니다. 귀하는 %s가 필요합니다. + %1$s (%2$s) 에 대한 거래 수수료는 %3$s로 지불되었습니다. 귀하는 %4$s가 필요합니다. 경고! 갇힐 위험 수수료 오류 요금이 너무 낮습니다. @@ -612,7 +605,6 @@ 적용 최소 %s Memo - 플랫폼에서 스왑 작업에 대한 서비스 수수료는 일반적으로 0.3% 또는 0.6%입니다. 올바르지 않은 마감 시간 올바르지 않은 슬립 귀하의 거래가 실패할 것 같습니다. diff --git a/app/src/main/res/values-pt-rBR/strings.xml b/app/src/main/res/values-pt-rBR/strings.xml index 2e6e8113e22..e321a2d0025 100644 --- a/app/src/main/res/values-pt-rBR/strings.xml +++ b/app/src/main/res/values-pt-rBR/strings.xml @@ -304,8 +304,6 @@ Procurando transações... %s tx Sincronizando… %s%% - Adicionar Moedas - Adicionar Moeda Desativar moeda %s Saldo Organizar por @@ -314,7 +312,6 @@ oculto Baixando Blocos Verificando Blocos - Você precisa fazer um backup da carteira %1$s antes de poder receber %2$s. Você ainda não tem nenhuma carteira instalada.\nCrie uma nova carteira ou restaure uma já existente Você não adicionou nenhuma moeda nesta carteira. Este endereço da carteira não tem nenhum saldo @@ -392,10 +389,6 @@ Não é possível enviar para você mesmo Saldo Disponível Velocidade da Transação - Baixo - Alto - Recomendado - Personalizado Taxa Próximo Desligado @@ -613,7 +606,6 @@ Aplicar %s min Endereço ou Domínio - Uma taxa de serviço para a ação de troca na plataforma normalmente 0,3% ou 0,6% Sem prazo Zero Slippage É provável que sua transação falhe. diff --git a/app/src/main/res/values-pt/strings.xml b/app/src/main/res/values-pt/strings.xml index 2a39c8a7a92..7ea0d916c29 100644 --- a/app/src/main/res/values-pt/strings.xml +++ b/app/src/main/res/values-pt/strings.xml @@ -278,8 +278,6 @@ Procurando transações... %s tx Sincronizando… %s%% - Adicionar Moedas - Adicionar Moeda Desativar moeda %s Saldo Organizar por @@ -288,7 +286,6 @@ oculto Baixando Blocos Verificando Blocos - Você precisa fazer um backup da carteira %1$s antes de poder receber %2$s. Você ainda não tem nenhuma carteira instalada.\nCrie uma nova carteira ou restaure uma já existente Você não tem moedas adicionadas.\nAdicione as moedas que você usará Este endereço da carteira não tem nenhum saldo @@ -299,7 +296,6 @@ Choose network to get an address to receive. Your address for depositing %s Watch address of %s - Send only %s to this address. Sending other types of tokens to this address will result in their ultimate loss. Choose a format for providing an address to receive. Address Format The Cash Address format is preferred for receiving Bitcoin Cash (BCH) due to its improved user experience and compatibility. However, both address formats can be used interchangeably to receive BCH, regardless of the sender\'s address format. @@ -344,10 +340,6 @@ Não é possível enviar para você mesmo Saldo Disponível Velocidade da Transação - Baixo - Alto - Recomendado - Personalizado Taxa Próximo Desligado @@ -542,7 +534,6 @@ Aplicar %s min Endereço ou Domínio - Uma taxa de serviço para a ação de troca na plataforma normalmente 0,3% ou 0,6% Sem prazo Zero Slippage É provável que sua transação falhe. @@ -764,20 +755,16 @@ Adicionar novo Adicionado Sincronizar Nó - Esta configuração controla como este aplicativo interage com blockchains ao enviar ou receber transações.\n\nNo caso do Bitcoin, Bitcoin Cash, Litecoin e Dash, a comunicação com os nós da rede blockchain é totalmente peer-to-peer. Os pings Unstoppable são feitos em muitos nós e se comunicam com um deles. Cada vez que o aplicativo se conecta a um nó diferente.\n\nNo caso da Ethereum, da Binance Smart Chain e outras blockchains de EVM, não existem alternativas para as carteiras móveis para interagir com as respectivas blockchains que não sejam por provedores de serviços RPC de terceiros (ex. Infura.io) ou nós pessoais. Isso essencialmente significa que sua comunicação com essa blockchain não é descentralizada. Isso não afeta seus fundos de forma alguma, apenas a capacidade de se conectar à rede blockchain.\n\nFique tranquilo, vamos mantê-lo no radar e em breve tentaremos fornecer uma forma descentralizada para sincronizar. Paciência. Url RPC Adicionar fonte RPC Nome Autenticação básica (opcional) - Fonte RPC Fonte RPC com esta url já existe Url inserida é inválida. URL válida deve ter um dos seguintes esquemas: http, https, ws, wss Após alterar a fonte de restauração, a carteira terá que ressincronizar-se com a blockchain do Bitcoin. - Restaurar Fonte Selecione uma fonte de dados para restauração de carteira. Restaurar da blockchain leva consideravelmente mais tempo. - Esta configuração só é relevante ao restaurar uma carteira existente. É um processo de obtenção de histórico de transações para uma determinada criptomoeda, então o aplicativo de carteira é capaz de exibir transações anteriores e calcular o saldo do usuário. Isto precisa acontecer apenas uma vez quando o usuário restaura as carteiras previamente criadas.\n\nNeste ponto, existem duas possíveis maneiras de uma carteira móvel como o Unstoppable de fazer isso:\n\n1. do Servidor API: Há um servidor predefinido por terceiros que hospeda toda a blockchain e tem todos os dados processados e otimizados para fornecer esses dados de forma rápida. Este método é rápido, mas potencialmente (não necessariamente) menos privado. É também um método centralizado para restaurar uma carteira, pois depende da disponibilidade de um servidor de terceiros. Esta opção é recomendada devido à velocidade de obtenção de dados (5-10 minutos).\n\n2. da Blockchain: O aplicativo tenta restaurar diretamente de uma rede de nós da blockchain. Essa é uma maneira descentralizada de restaurar o saldo das carteiras e transações anteriores. O aplicativo pança muitos dos nós da rede e solicita dados deles sem abordar alguns nós especificamente. Esta opção é lenta e pode levar facilmente 2-3 horas, o aplicativo precisa estar aberto enquanto a restauração está acontecendo. Este método de restauração não depende de nenhuma entidade e deve funcionar em todas as condições. Entrada/Saída Configurações de transação Entradas / Saídas de Transação @@ -805,7 +792,6 @@ Determinístico Bip69 Determinístico Indexação Lexicográfica - Recomendado Da Blockchain Mais Privado Duress Passcode @@ -937,18 +923,9 @@ Invalid Password Backup Password Endereço ou Domínio - Insira a chave pública estendida da conta - Disponível apenas para Ethereum e outras blockchains de EVM suportadas. Ver Escolha as Blockchains Escolher Moedas - Por - Assistir Por - Endereço EVM - Endereço Solana - Tron Address - Account xPubKey - xPubKey Inválida Nome Salvar @@ -1100,7 +1077,6 @@ Restaurar Fonte Após mudar a Restauração, a carteira terá que ressincronizar-se com a blockchain %s. Comunicação - CashAddress (recomendado) Comum antes de 2018 Comum depois de 2018 diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index 324550b5e59..320bb668a57 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -306,8 +306,6 @@ Поиск транзакций... %s tx Синхронизация… %s%% - Добавить токен - Добавить токен Отключена монета %s По балансу Сортировать @@ -316,7 +314,6 @@ скрытое Загрузка блоков Сканирование блоков - Вам нужно сделать резервную копию %s Кошелька, прежде чем вы сможете получать %s. У вас пока нет установленных кошельков.\nСоздайте новый кошелек или восстановите существующий кошелек Вы еще не добавили токены в этот кошелек. У кошелька с этим адресом нет баланса @@ -394,10 +391,6 @@ Отправка самому себе невозможна Доступный баланс Скорость транзакции - Низкая - Высокая - Рекомендовано - Индивидуальная Комиссия Далее Выкл. @@ -407,7 +400,7 @@ 1 год Отправка Комиссия - Комиссии за транзакцию %s (%s) взимаются в %s. Вам нужно %s. + Комиссии за транзакцию %1$s (%2$s) взимаются в %3$s. Вам нужно %4$s. Внимание! Транзакция может застрять в сети Ошибка комиссии Ставка комиссии слишком низкая. @@ -611,7 +604,6 @@ Применить %s мин Адрес или домен - Комиссия за услугу обмена на платформе обычно 0.3% или 0.6% Нулевой срок Нулевое отклонение Ваша транзакция, скорее всего, не удастся. diff --git a/app/src/main/res/values-tr/strings.xml b/app/src/main/res/values-tr/strings.xml index e62f14734e3..0588708efb3 100644 --- a/app/src/main/res/values-tr/strings.xml +++ b/app/src/main/res/values-tr/strings.xml @@ -2,7 +2,7 @@ Parametre ayarlanmadı - %s%s + %1$s%2$s İptal Kopyala Kapat @@ -302,8 +302,6 @@ İşlemler aranıyor ... %s tx Eşitleniyor...%s%% - Kredi Ekle - Para Ekle engelli madeni para %s Bakiye Sıralama şekli @@ -312,7 +310,6 @@ gizli Blokları İndirme Tarama Blokları - Öncelikle %s cüzdanınızı yedeklemeniz gerekiyor daha sonra %s kripto parasını alabilirsiniz. Henüz cüzdan yok Bu cüzdana hiç jeton eklemediniz. Bu cüzdan adresinde bakiye bulunmuyor @@ -390,10 +387,6 @@ Kendine gönderme desteklenmiyor Mevcut Bakiye İşlem hızı - Yavaş - Hızlı - Tavsiye Edilen - Özel Masraf: İleri Kapat @@ -403,7 +396,7 @@ 1 yıl Gönderiliyor Ücret oranı - %s (%s) için ișlem ücreti %s hesabından ödenir. Asgari %s gerekiyor. + %1$s (%2$s) için ișlem ücreti %3$s hesabından ödenir. Asgari %4$s gerekiyor. Uyarı! Takılma riski Ücret Hatası Ücret Oranı çok düşük. @@ -611,7 +604,6 @@ Uygula %s dk Adres veya Domain - Platformdaki takas işlemi için bir hizmet ücreti genellikle %0,3 veya %0,6\'dır Geçersiz Son Tarih Geçersiz Kayma İşleminizin başarısız olması muhtemeldir. diff --git a/app/src/main/res/values-zh/strings.xml b/app/src/main/res/values-zh/strings.xml index 099ca10a277..4d695750351 100644 --- a/app/src/main/res/values-zh/strings.xml +++ b/app/src/main/res/values-zh/strings.xml @@ -2,7 +2,7 @@ 参数未设置 - %s%s + %1$s%2$s 取消 复制 关闭 @@ -304,8 +304,6 @@ 正在搜索交易… %s tx 正在同步... %s%% - 添加代币 - 添加代币 已禁用代币%s 余额 排序 @@ -314,7 +312,6 @@ 隐藏 正在下载块 扫描块 - 您必须在接收%s之前先备份%s钱包。 尚无钱包 您还没有添加任何代币到此钱包中。 此钱包地址没有任何余额 @@ -392,10 +389,6 @@ 不支持发送给自己 可用余额 交易速度 - - - 推荐 - 自定义 费用: 继续 @@ -609,7 +602,6 @@ 应用 %s分钟。 地址或域名 - 典型平台上交换动作的服务费:0.3% 或 0.6% 没有截止日期 没有滑点 滑点太小,您的交易可能失败。 diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 9bb50b3a49b..34707fc7b08 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -364,8 +364,6 @@ Searching transactions… %s tx Syncing… %s%% - Add Coins - Add Coin Disabled coin %s Balance Sort by @@ -374,7 +372,6 @@ hidden Downloading Blocks Scanning Blocks - You need to backup the %1$s Wallet before you may receive %2$s. You don\'t have any installed wallets yet.\nCreate a new wallet or restore an existing one You haven\'t added any coins to this wallet. This wallet address doesn\'t have any balance @@ -466,10 +463,6 @@ Available Balance Transaction Speed - Low - High - Recommended - Custom sat/byte Fee Memo @@ -715,7 +708,6 @@ Apply %s min Address or domain - A service fee for the swap action on the platform typically either 0.3% or 0.6% Zero Deadline Zero Slippage