From 141d1ebc1db1749d80432cefc437ad165c93d2c1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ioan=20Biz=C4=83u?= Date: Fri, 1 Nov 2024 11:02:07 +0100 Subject: [PATCH] fix(core/ui): remove unnecessary newline [no changelog] (cherry picked from commit 2435e8b10113bee150d169db150dcf6305f163fb) --- core/embed/rust/src/ui/model_tr/layout.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/embed/rust/src/ui/model_tr/layout.rs b/core/embed/rust/src/ui/model_tr/layout.rs index 7cd85eb883..f4879ce5ab 100644 --- a/core/embed/rust/src/ui/model_tr/layout.rs +++ b/core/embed/rust/src/ui/model_tr/layout.rs @@ -1114,7 +1114,10 @@ extern "C" fn new_show_warning(n_args: usize, args: *const Obj, kwargs: *mut Map let mut ops = OpTextLayout::new(theme::TEXT_NORMAL); ops = ops.alignment(geometry::Alignment::Center); if !warning.is_empty() { - ops = ops.text_bold_upper(warning).newline(); + ops = ops.text_bold_upper(warning); + if !description.is_empty() { + ops = ops.newline(); + } } if !description.is_empty() { ops = ops.text_normal(description);