config: abstract away mempool depth format str "%.1f MB from tip"
related: 4dd94172a6
(as that commit introduced depth targets that need more precision to display)
This commit is contained in:
@@ -125,6 +125,7 @@ class TxDialog(Factory.Popup):
|
||||
self.app = app # type: ElectrumWindow
|
||||
self.wallet = self.app.wallet
|
||||
self.tx = tx # type: Transaction
|
||||
self.config = self.app.electrum_config
|
||||
|
||||
# If the wallet can populate the inputs with more info, do it now.
|
||||
# As a result, e.g. we might learn an imported address tx is segwit,
|
||||
@@ -154,7 +155,7 @@ class TxDialog(Factory.Popup):
|
||||
self.date_str = datetime.fromtimestamp(tx_mined_status.timestamp).isoformat(' ')[:-3]
|
||||
elif exp_n is not None:
|
||||
self.date_label = _('Mempool depth')
|
||||
self.date_str = _('{} from tip').format('%.2f MB'%(exp_n/1000000))
|
||||
self.date_str = self.config.depth_tooltip(exp_n)
|
||||
else:
|
||||
self.date_label = ''
|
||||
self.date_str = ''
|
||||
|
||||
Reference in New Issue
Block a user