Browse Source

fix Settings dialog in text gui

283
ThomasV 9 years ago
parent
commit
88c238dda7
  1. 8
      gui/text.py

8
gui/text.py

@ -393,13 +393,11 @@ class ElectrumGui:
def settings_dialog(self):
fee = str(Decimal(self.wallet.fee_per_kb(self.config)) / COIN)
out = self.run_dialog('Settings', [
{'label':'Default GUI', 'type':'list', 'choices':['classic','lite','gtk','text'], 'value':self.config.get('gui')},
{'label':'Default fee', 'type':'satoshis', 'value': format_satoshis(self.wallet.fee_per_kb).strip() }
{'label':'Default fee', 'type':'satoshis', 'value': fee }
], buttons = 1)
if out:
if out.get('Default GUI'):
self.config.set_key('gui', out['Default GUI'], True)
if out.get('Default fee'):
fee = int(Decimal(out['Default fee']) * COIN)
self.config.set_key('fee_per_kb', fee, True)
@ -453,7 +451,7 @@ class ElectrumGui:
w.addstr( 2+interval*i, 2, label, curses.A_REVERSE if self.popup_pos%numpos==i else 0)
if buttons:
w.addstr( 5+interval*i, 10, "[ ok ]", curses.A_REVERSE if self.popup_pos%numpos==(numpos-2) else curses.color_pair(2))
w.addstr( 5+interval*i, 10, "[ ok ]", curses.A_REVERSE if self.popup_pos%numpos==(numpos-2) else curses.color_pair(2))
w.addstr( 5+interval*i, 25, "[cancel]", curses.A_REVERSE if self.popup_pos%numpos==(numpos-1) else curses.color_pair(2))
w.refresh()

Loading…
Cancel
Save