electrum

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

commit caccae222cbb9bb7f4658a813274f1796c9a3601
parent b9776201ce361e32ef20593908cd8c0b1762eedf
Author: ThomasV <thomasv@electrum.org>
Date:   Thu, 18 Feb 2016 12:13:19 +0100

kivy: improve status dialog

Diffstat:
Mgui/kivy/main.kv | 15++++++++++-----
Mgui/kivy/uix/ui_screens/status.kv | 111++++++++++++++++++++++++++++++++++---------------------------------------------
2 files changed, 57 insertions(+), 69 deletions(-)

diff --git a/gui/kivy/main.kv b/gui/kivy/main.kv @@ -125,14 +125,14 @@ size: self.size pos: self.pos -<TxHashLabel@TopLabel> +<RefLabel@TopLabel> font_size: '6pt' - tx_hash: '' - text: '[ref=x]%s[/ref]' %' '.join(map(''.join, zip(*[iter(self.tx_hash)]*4))) if self.tx_hash else '' + ref_text: '' + text: '[ref=x]%s[/ref]' % self.ref_text padding: '10dp', '10dp' on_ref_press: - app._clipboard.copy(self.text) - app.show_info(_('Transaction ID copied to clipboard')) + app._clipboard.copy(self.ref_text) + app.show_info(_('Text copied to clipboard')) canvas.before: Color: rgb: .3, .3, .3 @@ -140,6 +140,11 @@ size: self.size pos: self.pos +<TxHashLabel@RefLabel> + tx_hash: '' + ref_text: self.tx_hash + text: '[ref=x]%s[/ref]' %' '.join(map(''.join, zip(*[iter(self.tx_hash)]*4))) if self.tx_hash else '' + <InfoBubble> size_hint: None, None width: '270dp' if root.fs else min(self.width, dp(270)) diff --git a/gui/kivy/uix/ui_screens/status.kv b/gui/kivy/uix/ui_screens/status.kv @@ -7,73 +7,56 @@ Popup: unmatured: 0 on_parent: self.confirmed, self.unconfirmed, self.unmatured = app.wallet.get_balance() + BoxLayout: orientation: 'vertical' - spacing: '1dp' - GridLayout: - cols:2 - Label: - text: _("Wallet Name:") - text_size: self.size - halign: 'left' - Label: - text: os.path.basename(app.wallet.storage.path) - text_size: self.size - halign: 'left' - Label: - text: _("Wallet type:") - text_size: self.size - halign: 'left' - Label: - text: app.wallet.wallet_type - text_size: self.size - halign: 'left' - Label: - text: _("Balance") + ':' - text_size: self.size - halign: 'left' - Label: - text: app.format_amount_and_units(root.confirmed + root.unconfirmed + root.unmatured) - text_size: self.size - halign: 'left' + ScrollView: + GridLayout: + cols: 1 + height: self.minimum_height + size_hint_y: None + padding: '10dp' + spacing: '10dp' + padding: '10dp' + spacing: '10dp' + GridLayout: + cols: 1 + size_hint_y: None + height: self.minimum_height + spacing: '10dp' + BoxLabel: + text: _('Wallet Name') + value: os.path.basename(app.wallet.storage.path) + BoxLabel: + text: _("Wallet type:") + value: app.wallet.wallet_type + BoxLabel: + text: _("Balance") + ':' + value: app.format_amount_and_units(root.confirmed + root.unconfirmed + root.unmatured) + BoxLabel: + text: _("Confirmed") + ':' + opacity: 1 if root.confirmed else 0 + value: app.format_amount_and_units(root.confirmed) + opacity: 1 if root.confirmed else 0 + BoxLabel: + text: _("Unconfirmed") + ':' + opacity: 1 if root.unconfirmed else 0 + value: app.format_amount_and_units(root.unconfirmed) + BoxLabel: + text: _("Unmatured") + ':' + opacity: 1 if root.unmatured else 0 + value: app.format_amount_and_units(root.unmatured) + opacity: 1 if root.unmatured else 0 + + TopLabel: + text: _('Master Public Key') + RefLabel: + ref_text: app.wallet.get_master_public_key() + + TopLabel: + text: '' + id: seed_label - Label: - text: _("Confirmed") + ':' - opacity: 1 if root.confirmed else 0 - text_size: self.size - halign: 'left' - Label: - text: app.format_amount_and_units(root.confirmed) - opacity: 1 if root.confirmed else 0 - text_size: self.size - halign: 'left' - Label: - text: _("Unconfirmed") + ':' - text_size: self.size - halign: 'left' - opacity: 1 if root.unconfirmed else 0 - Label: - text: app.format_amount_and_units(root.unconfirmed) - opacity: 1 if root.unconfirmed else 0 - text_size: self.size - halign: 'left' - Label: - text: _("Unmatured") + ':' - text_size: self.size - halign: 'left' - opacity: 1 if root.unmatured else 0 - Label: - text: app.format_amount_and_units(root.unmatured) - opacity: 1 if root.unmatured else 0 - text_size: self.size - halign: 'left' - Label: - text: '' - id: seed_label - text_size: self.width, None - size: self.texture_size - Widget: - size_hint: None, 1 BoxLayout: size_hint: 1, None height: '48dp'