electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 97056ae44dca6775c8aff56033ff461060984079
parent ca6654c10234e1d3ded7ff0c6b1f42fa25438010
Author: SomberNight <somber.night@protonmail.com>
Date:   Tue, 19 Nov 2019 21:22:49 +0100

qt send tab: subtract 2fa fee when clicking "spend max"

Diffstat:
Melectrum/gui/qt/main_window.py | 10++++------
1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/electrum/gui/qt/main_window.py b/electrum/gui/qt/main_window.py @@ -1292,12 +1292,10 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, Logger): is_sweep=False) tx = make_tx(None) - amount = tx.output_value()#sum(x.value_sats() for x in self.get_coins()) - self.amount_e.setAmount(amount) - ## substract extra fee - #__, x_fee_amount = run_hook('get_tx_extra_fee', self.wallet, tx) or (None, 0) - #amount_after_all_fees = amount - x_fee_amount - #self.amount_e.setAmount(amount_after_all_fees) + amount = tx.output_value() + __, x_fee_amount = run_hook('get_tx_extra_fee', self.wallet, tx) or (None, 0) + amount_after_all_fees = amount - x_fee_amount + self.amount_e.setAmount(amount_after_all_fees) def get_contact_payto(self, key): _type, label = self.contacts.get(key)