mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-06-28 12:29:51 +00:00
Solana enhancements (#1907)
* fix: Confirm widget is still mounted * feat: Modify balance display to include full balance * fix: Modifying balance * chore: Feature cleanup * fix: Add frozen balance into consideration when taking available balance and add field to make full balance display only on bitcoin and litecoin wallets * fix: Adjust balance card to display correct available and unavailable balance, unavailable balance should only be displayed when there is one WIP * fix: Cleanup balance page and balance page view_model * chore: Revert formatting * fix: Remove full balance * fix: Remove full balance * fix: Remove full balance * chore: Rever formating [skip ci] * feat: Finalize display only available and unavailable balance * fix: Modify the way balance is displayed, activate frozen balance with label, remove unavailable/additional balance for bitcoin wallet type * fix: Issues coming from syncing with main * fix: Modify additional balance label * fix: Monero and Wownero balances display bug * fix: Resolve merge conflicts * feat: Activate CPFP for BTC, LTC and BCH, also fix issues with frozen balance display * - minor fix - remove unused functions * Fix conflicts * Temporarily remove misused function Ignore creating associated account for receiver (testing) * revert associated recipient account removal * Migrate eth and polygon nodes to new urls and https --------- Co-authored-by: Blazebrain <davidadegoke16@gmail.com> Co-authored-by: tuxsudo <tuxsudo@tux.pizza>
This commit is contained in:
parent
c9a6abeea4
commit
4bba9f6ddb
4 changed files with 50 additions and 14 deletions
|
@ -379,16 +379,18 @@ class SolanaWalletClient {
|
|||
required double solBalance,
|
||||
required double fee,
|
||||
}) async {
|
||||
final rent =
|
||||
await _client!.getMinimumBalanceForMintRentExemption(commitment: Commitment.confirmed);
|
||||
|
||||
final rentInSol = (rent / lamportsPerSol).toDouble();
|
||||
|
||||
final remnant = solBalance - (inputAmount + fee);
|
||||
|
||||
if (remnant > rentInSol) return true;
|
||||
|
||||
return false;
|
||||
return true;
|
||||
// TODO: this is not doing what the name inclines
|
||||
// final rent =
|
||||
// await _client!.getMinimumBalanceForMintRentExemption(commitment: Commitment.confirmed);
|
||||
//
|
||||
// final rentInSol = (rent / lamportsPerSol).toDouble();
|
||||
//
|
||||
// final remnant = solBalance - (inputAmount + fee);
|
||||
//
|
||||
// if (remnant > rentInSol) return true;
|
||||
//
|
||||
// return false;
|
||||
}
|
||||
|
||||
Future<PendingSolanaTransaction> _signNativeTokenTransaction({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue