electrum

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

commit 1635c149bd7399beb346a6a91466e988746aaf43
parent ceba4af01a86762422c484ac31ca2057a83d338c
Author: SomberNight <somber.night@protonmail.com>
Date:   Mon,  2 Jul 2018 22:50:19 +0200

fix #4491

Diffstat:
Mgui/kivy/main_window.py | 9++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/gui/kivy/main_window.py b/gui/kivy/main_window.py @@ -68,7 +68,8 @@ Label.register('Roboto', 'gui/kivy/data/fonts/Roboto-Bold.ttf') -from electrum.util import base_units, NoDynamicFeeEstimates +from electrum.util import (base_units, NoDynamicFeeEstimates, decimal_point_to_base_unit_name, + base_unit_name_to_decimal_point) class ElectrumWindow(App): @@ -159,11 +160,13 @@ class ElectrumWindow(App): self._trigger_update_history() def _get_bu(self): - return self.electrum_config.get('base_unit', 'mBTC') + decimal_point = self.electrum_config.get('decimal_point', 5) + return decimal_point_to_base_unit_name(decimal_point) def _set_bu(self, value): assert value in base_units.keys() - self.electrum_config.set_key('base_unit', value, True) + decimal_point = base_unit_name_to_decimal_point(value) + self.electrum_config.set_key('decimal_point', decimal_point, True) self._trigger_update_status() self._trigger_update_history()