From 491aeaa0f5ff5aba7d6f7e5362f977c3d4085b3b Mon Sep 17 00:00:00 2001 From: tychovrahe Date: Wed, 29 May 2024 10:31:25 +0200 Subject: [PATCH] feat(core): add value info to brightness dialog in mercury [no changelog] --- .../component/number_input_slider.rs | 42 +++++++++++++++---- 1 file changed, 34 insertions(+), 8 deletions(-) diff --git a/core/embed/rust/src/ui/model_mercury/component/number_input_slider.rs b/core/embed/rust/src/ui/model_mercury/component/number_input_slider.rs index 8af13045a..4075f1ad2 100644 --- a/core/embed/rust/src/ui/model_mercury/component/number_input_slider.rs +++ b/core/embed/rust/src/ui/model_mercury/component/number_input_slider.rs @@ -1,10 +1,13 @@ -use crate::ui::{ - component::{base::ComponentExt, Child, Component, Event, EventCtx}, - constant::screen, - display, - event::TouchEvent, - geometry::{Grid, Insets, Point, Rect}, - shape::{self, Renderer}, +use crate::{ + strutil::ShortString, + ui::{ + component::{base::ComponentExt, Child, Component, Event, EventCtx}, + constant::screen, + display, + event::TouchEvent, + geometry::{Alignment, Grid, Insets, Point, Rect}, + shape::{self, Renderer}, + }, }; use super::{theme, Button, ButtonMsg}; @@ -17,15 +20,20 @@ pub enum NumberInputSliderDialogMsg { pub struct NumberInputSliderDialog { area: Rect, + text_area: Rect, input: Child, cancel_button: Child