URI: 
       tgat_wallet_delta: reverse sign of returned fee - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit 0843aaafb5ce7a1e460ca6c7cd2b87af5d155750
   DIR parent 79fbb5edcee2a6bd1225ca568c22b48718ab6636
  HTML Author: ThomasV <thomasv@electrum.org>
       Date:   Thu,  2 Jun 2016 11:30:39 +0200
       
       gat_wallet_delta: reverse sign of returned fee
       
       Diffstat:
         M gui/kivy/uix/dialogs/tx_dialog.py   |       4 ++--
         M gui/qt/main_window.py               |       1 -
         M gui/qt/transaction_dialog.py        |       4 ++--
         M lib/wallet.py                       |       2 +-
       
       4 files changed, 5 insertions(+), 6 deletions(-)
       ---
   DIR diff --git a/gui/kivy/uix/dialogs/tx_dialog.py b/gui/kivy/uix/dialogs/tx_dialog.py
       t@@ -127,8 +127,8 @@ class TxDialog(Factory.Popup):
                if is_relevant:
                    if is_mine:
                        if fee is not None:
       -                    self.amount_str = self.app.format_amount_and_units(-v+fee)
       -                    self.fee_str = self.app.format_amount_and_units(-fee)
       +                    self.amount_str = self.app.format_amount_and_units(-v-fee)
       +                    self.fee_str = self.app.format_amount_and_units(fee)
                        else:
                            self.amount_str = self.app.format_amount_and_units(-v)
                            self.fee_str = _("unknown")
   DIR diff --git a/gui/qt/main_window.py b/gui/qt/main_window.py
       t@@ -2711,7 +2711,6 @@ class ElectrumWindow(QMainWindow, MessageBoxMixin, PrintError):
        
            def bump_fee_dialog(self, tx):
                is_relevant, is_mine, v, fee = self.wallet.get_wallet_delta(tx)
       -        fee = -fee
                d = WindowModalDialog(self, _('Bump Fee'))
                vbox = QVBoxLayout(d)
                vbox.addWidget(QLabel(_('Current fee') + ': %s'% self.format_amount(fee) + ' ' + self.base_unit()))
   DIR diff --git a/gui/qt/transaction_dialog.py b/gui/qt/transaction_dialog.py
       t@@ -234,7 +234,7 @@ class TxDialog(QDialog, MessageBoxMixin):
                if is_relevant:
                    if is_mine:
                        if fee is not None:
       -                    amount_str = _("Amount sent:") + ' %s'% format_amount(-v+fee) + ' ' + base_unit
       +                    amount_str = _("Amount sent:") + ' %s'% format_amount(-v-fee) + ' ' + base_unit
                        else:
                            amount_str = _("Amount sent:") + ' %s'% format_amount(-v) + ' ' + base_unit
                    else:
       t@@ -244,7 +244,7 @@ class TxDialog(QDialog, MessageBoxMixin):
        
                if fee is None:
                    fee = self.wallet.tx_fees.get(tx_hash)
       -        fee_str = _("Transaction fee") + ': %s'% (format_amount(-fee) + ' ' + base_unit if fee is not None else _('unknown'))
       +        fee_str = _("Transaction fee") + ': %s'% (format_amount(fee) + ' ' + base_unit if fee is not None else _('unknown'))
        
                self.amount_label.setText(amount_str)
                self.fee_label.setText(fee_str)
   DIR diff --git a/lib/wallet.py b/lib/wallet.py
       t@@ -596,7 +596,7 @@ class Abstract_Wallet(PrintError):
                        fee = None
                    else:
                        # all inputs are mine
       -                fee = v_out - v_in
       +                fee = v_in - v_out
                if not is_mine:
                    fee = None
                return is_relevant, is_mine, v, fee