From f56aaa3b1c837ba8f0d6fe7fef2a42f4d2e8ad54 Mon Sep 17 00:00:00 2001 From: Peter Jensen Date: Mon, 5 Feb 2018 14:26:12 +0100 Subject: [PATCH] ui/pin: check maxlength --- assets/lock.png | Bin 1116 -> 1164 bytes src/apps/common/request_pin.py | 4 +++- src/trezor/res/lock.toig | Bin 102 -> 72 bytes src/trezor/ui/pin.py | 5 +++++ 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/assets/lock.png b/assets/lock.png index 4c5dadea381933d5ffb49197985181e529dff366..e2df8e611e5a3a521d0a1e5e16c3ea6284e90fa8 100644 GIT binary patch delta 325 zcmcb^(Zgxh8Q|y6%O%Cdz`(%k>ERLtr1^kYfCES{mi$mG0MeWV9+AZi4BWyX%*Zfn zj>JZ@VCMRFo-U3d6}OTScbxw;pAo3;|NkV-H|Z~5Geg*k74NHip4uNyWCQX+l8Hag zAK%pR(cU{phnbt18K$fwx+1QB=ET(5C;wOf@8#Q6VPwE!Y;a@apY#L}VCZOV{65L) zAq$&Wn}7ZJ@B8CV96Iu#;7R@7%TCk&@(92GT%DJ^G1Z2R3&JT}y#C+PCjg9Tz zQyvgFc(7peg`Q&v_ntZMWBx~b=EwDHY;J692N-7EwRkuCOj8KRH=eG3tS;-E5}E*R CJcT3x delta 276 zcmeC-yu)GE8Q|y6%O%Cdz`(%k>ERLtq~(BEi~~q8eBvk;22z{_9+AZi3~u*8n6XdI zD0-t=FmwGrPZ!6Kid#tu4oo`5@9xAOJJ`UyV&0$sKrs2*jnt=p|K=y<-uw1{iDB5w z$^V@tB_t%~)Xz;hvZ_+C<>HU~B6=rS(lux1wi#?Qwn&`#EaeAl;-9n!hn4=yD*lyy z7;4cy+p%G8Yh&ZXeg$Uh7=dRVD;bVYkT(DE-}v8ut>ybeil3j$Uh!_v}h~WB+-2{!9KhF7j>SVrFAF Xd(KI|AoS%gkWW2b{an^LB{Ts5-b8mh diff --git a/src/apps/common/request_pin.py b/src/apps/common/request_pin.py index 9a03c2fa79..e65617a045 100644 --- a/src/apps/common/request_pin.py +++ b/src/apps/common/request_pin.py @@ -16,8 +16,10 @@ async def request_pin(code: int = None) -> str: def onchange(): c = dialog.cancel if matrix.pin: - c.content = res.load(ui.ICON_CLEAR) + c.normal_style = ui.BTN_CLEAR['normal'] + c.content = res.load(ui.ICON_BACK) else: + c.normal_style = ui.BTN_CANCEL['normal'] c.content = res.load(ui.ICON_LOCK) c.taint() c.render() diff --git a/src/trezor/res/lock.toig b/src/trezor/res/lock.toig index 778e7ad69acf5ca03bc6b7f41e4ca9cdfeb89d27..b258b164526d2c4a317a2cb226d3449989b271b7 100644 GIT binary patch literal 72 zcmV-O0Jr~CPf2GE01yB?0001EV5t3noq>UY^Z)<<6B!ud|DXB)m4RXYFQxTA85q_- eX0ZFkAhiA~L;NqrJ@5alI{)wVe=@;c2mk=VIV1D{ literal 102 zcmV-s0Ga<(Pf2GU02TmR0001EU;qKmy9*c)fa(1IKL!Y{%unO~!wByA00x#na313+ zAkhz3&GHpU*cZULUqIXj6s~>&s$!TdW7gl*yLaE;t^nck{)d1AsN4+@F3$jQ(Oks| I