1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-23 06:48:16 +00:00

src/trezor/ui: add new BTN_KEY_CONFIRM style to mnemonic keyboard, use that one

This commit is contained in:
Pavol Rusnak 2018-02-07 19:48:32 +01:00
parent 329b7d1488
commit 984327fea5
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
2 changed files with 26 additions and 2 deletions

View File

@ -34,8 +34,8 @@ class Input(Button):
self.taint()
if content == word: # confirm button
self.enable()
self.normal_style = ui.BTN_CONFIRM['normal']
self.active_style = ui.BTN_CONFIRM['active']
self.normal_style = ui.BTN_KEY_CONFIRM['normal']
self.active_style = ui.BTN_KEY_CONFIRM['active']
self.icon = ui.ICON_CONFIRM
elif word: # auto-complete button
self.enable()

View File

@ -179,6 +179,30 @@ BTN_KEY = {
}
}
BTN_KEY_CONFIRM = {
'normal': {
'bg-color': GREEN,
'fg-color': FG,
'text-style': MONO,
'border-color': BG,
'radius': RADIUS,
},
'active': {
'bg-color': FG,
'fg-color': GREEN,
'text-style': MONO,
'border-color': FG,
'radius': RADIUS,
},
'disabled': {
'bg-color': BG,
'fg-color': GREY,
'text-style': MONO,
'border-color': BG,
'radius': RADIUS,
}
}
# loader
LDR_DEFAULT = {
'normal': {