From ce142ffe0893cfed14c480eae94b23471b543046 Mon Sep 17 00:00:00 2001 From: tychovrahe Date: Thu, 2 Jun 2022 22:00:13 +0200 Subject: [PATCH] feat(core/rust): make ButtonPos hit function public to enable reuse --- core/embed/rust/src/ui/model_tr/component/button.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/embed/rust/src/ui/model_tr/component/button.rs b/core/embed/rust/src/ui/model_tr/component/button.rs index cf9ee45d0..a631e188f 100644 --- a/core/embed/rust/src/ui/model_tr/component/button.rs +++ b/core/embed/rust/src/ui/model_tr/component/button.rs @@ -18,7 +18,7 @@ pub enum ButtonPos { } impl ButtonPos { - fn hit(&self, b: &PhysicalButton) -> bool { + pub fn hit(&self, b: &PhysicalButton) -> bool { matches!( (self, b), (Self::Left, PhysicalButton::Left) | (Self::Right, PhysicalButton::Right)