URI: 
       tadd batch_rbf option to Qt GUI - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit f55db2f90b7ad0114deea178ac9d3fc2dee4fe1a
   DIR parent 2b8d801b366a12a6eb84f49ce2ca23b772d9d045
  HTML Author: ThomasV <thomasv@electrum.org>
       Date:   Fri,  9 Nov 2018 17:09:23 +0100
       
       add batch_rbf option to Qt GUI
       
       Diffstat:
         M electrum/gui/qt/main_window.py      |      17 +++++++++++++++--
         M electrum/wallet.py                  |       2 +-
       
       2 files changed, 16 insertions(+), 3 deletions(-)
       ---
   DIR diff --git a/electrum/gui/qt/main_window.py b/electrum/gui/qt/main_window.py
       t@@ -2746,17 +2746,30 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError):
                feebox_cb.stateChanged.connect(on_feebox)
                fee_widgets.append((feebox_cb, None))
        
       +        use_rbf = self.config.get('use_rbf', True)
                use_rbf_cb = QCheckBox(_('Use Replace-By-Fee'))
       -        use_rbf_cb.setChecked(self.config.get('use_rbf', True))
       +        use_rbf_cb.setChecked(use_rbf)
                use_rbf_cb.setToolTip(
                    _('If you check this box, your transactions will be marked as non-final,') + '\n' + \
                    _('and you will have the possibility, while they are unconfirmed, to replace them with transactions that pay higher fees.') + '\n' + \
                    _('Note that some merchants do not accept non-final transactions until they are confirmed.'))
                def on_use_rbf(x):
       -            self.config.set_key('use_rbf', x == Qt.Checked)
       +            self.config.set_key('use_rbf', bool(x))
       +            batch_rbf_cb.setEnabled(bool(x))
                use_rbf_cb.stateChanged.connect(on_use_rbf)
                fee_widgets.append((use_rbf_cb, None))
        
       +        batch_rbf_cb = QCheckBox(_('Batch RBF transactions'))
       +        batch_rbf_cb.setChecked(self.config.get('batch_rbf', False))
       +        batch_rbf_cb.setEnabled(use_rbf)
       +        batch_rbf_cb.setToolTip(
       +            _('If you check this box, your unconfirmed transactios will be consolidated in a single transaction') + '\n' + \
       +            _('This will save fees.'))
       +        def on_batch_rbf(x):
       +            self.config.set_key('batch_rbf', bool(x))
       +        batch_rbf_cb.stateChanged.connect(on_batch_rbf)
       +        fee_widgets.append((batch_rbf_cb, None))
       +
                msg = _('OpenAlias record, used to receive coins and to sign payment requests.') + '\n\n'\
                      + _('The following alias providers are available:') + '\n'\
                      + '\n'.join(['https://cryptoname.co/', 'http://xmr.link']) + '\n\n'\
   DIR diff --git a/electrum/wallet.py b/electrum/wallet.py
       t@@ -593,7 +593,7 @@ class Abstract_Wallet(AddressSynchronizer):
                    coin_chooser = coinchooser.get_coin_chooser(config)
                    # If there is an unconfirmed RBF tx, merge with it
                    base_tx = self.get_unconfirmed_tx()
       -            if base_tx and not base_tx.is_final():
       +            if config.get('batch_rbf', False) and base_tx and not base_tx.is_final():
                        base_tx = Transaction(base_tx.serialize())
                        base_tx.deserialize(force_full_parse=True)
                        base_tx.remove_signatures()