-WIP-electrum-btcp/gui/kivy/uix/ui_screens/amount.kv

92 lines
2.5 KiB
Plaintext
Raw Normal View History

2015-10-16 05:59:26 -07:00
#:import Decimal decimal.Decimal
2015-10-14 02:44:01 -07:00
Popup:
id: popup
title: _('Amount')
2015-10-16 05:59:26 -07:00
AnchorLayout:
anchor_x: 'center'
2015-10-14 02:44:01 -07:00
2015-10-16 02:18:24 -07:00
BoxLayout:
2015-10-16 05:59:26 -07:00
orientation: 'vertical'
size_hint: 0.8, 1
BoxLayout:
size_hint: 1, None
2015-10-14 06:13:47 -07:00
height: '48dp'
2015-10-16 05:59:26 -07:00
Label:
id: a
amount: ''
2015-12-02 03:11:28 -08:00
is_fiat: False
text: app.get_amount_text(self.amount, self.is_fiat)
2015-10-16 05:59:26 -07:00
Widget:
size_hint_x: 1
2015-12-02 03:11:28 -08:00
Button:
id: button_fiat
size_hint: 1, None
height: '48dp'
text: '<->'
on_release: a.is_fiat = not a.is_fiat
2015-10-16 05:59:26 -07:00
Widget:
size_hint: 1, 1
2015-10-14 02:44:01 -07:00
2015-10-16 05:59:26 -07:00
GridLayout:
size_hint: 1, None
height: '300dp'
cols: 3
KButton:
text: '1'
label: a
KButton:
text: '2'
label: a
KButton:
text: '3'
label: a
KButton:
text: '4'
label: a
KButton:
text: '5'
label: a
KButton:
text: '6'
label: a
KButton:
text: '7'
label: a
KButton:
text: '8'
label: a
KButton:
text: '9'
label: a
KButton:
text: '.'
label: a
KButton:
text: '0'
label: a
KButton:
text: '<'
label: a
Button:
id: but_max
size_hint: 1, None
height: '48dp'
text: 'Max'
on_release: a.amount = app.get_max_amount()
2015-10-16 05:59:26 -07:00
BoxLayout:
size_hint: 1, None
height: '48dp'
Widget:
size_hint: 0.7, None
height: '48dp'
Button:
size_hint: 0.3, None
height: '48dp'
text: _('OK')
on_release: popup.dismiss()