tqt tx dialog: disable "Finalize" btn if tx is None - electrum - Electrum Bitcoin wallet (HTM) git clone https://git.parazyd.org/electrum (DIR) Log (DIR) Files (DIR) Refs (DIR) Submodules --- (DIR) commit 13b858ab26f3eda6e89330ec9dfe707eecc95d62 (DIR) parent 66ddedb97ea2eef37cb9355de35e5ad534013373 (HTM) Author: SomberNight <somber.night@protonmail.com> Date: Tue, 19 Nov 2019 19:35:57 +0100 qt tx dialog: disable "Finalize" btn if tx is None e.g. NotEnoughFunds due to too high fee Diffstat: M electrum/gui/qt/transaction_dialog… | 3 +++ 1 file changed, 3 insertions(+), 0 deletions(-) --- (DIR) diff --git a/electrum/gui/qt/transaction_dialog.py b/electrum/gui/qt/transaction_dialog.py t@@ -365,6 +365,7 @@ class BaseTxDialog(QDialog, MessageBoxMixin): def update(self): if not self.finalized: self.update_fee_fields() + self.finalize_button.setEnabled(self.tx is not None) if self.tx is None: return self.update_io() t@@ -775,6 +776,8 @@ class PreviewTxDialog(BaseTxDialog, TxEditor): self.feerounding_icon.setVisible(abs(feerounding) >= 1) def on_finalize(self): + if not self.tx: + return self.finalized = True self.tx.set_rbf(self.rbf_cb.isChecked()) for widget in [self.fee_slider, self.feecontrol_fields, self.rbf_cb]: