mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-01-26 23:32:03 +00:00
fix(core): mercury ui animations only ask for frame on timer event
[no changelog]
This commit is contained in:
parent
e53e7cc13b
commit
429a558d78
@ -231,9 +231,12 @@ impl Component for HoldToConfirm {
|
||||
}
|
||||
_ => (),
|
||||
}
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
|
||||
if let Event::Timer(EventCtx::ANIM_FRAME_TIMER) = event {
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
}
|
||||
}
|
||||
None
|
||||
}
|
||||
|
@ -166,9 +166,11 @@ impl Component for StatusScreen {
|
||||
ctx.request_paint();
|
||||
ctx.request_anim_frame();
|
||||
}
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
if let Event::Timer(EventCtx::ANIM_FRAME_TIMER) = event {
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
}
|
||||
}
|
||||
|
||||
match self.dismiss_type {
|
||||
|
@ -179,9 +179,11 @@ impl Component for TapToConfirm {
|
||||
}
|
||||
_ => (),
|
||||
}
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
if let Event::Timer(EventCtx::ANIM_FRAME_TIMER) = event {
|
||||
if self.anim.is_active() {
|
||||
ctx.request_anim_frame();
|
||||
ctx.request_paint();
|
||||
}
|
||||
}
|
||||
if self.anim.is_finished() {
|
||||
return Some(());
|
||||
|
Loading…
Reference in New Issue
Block a user