From 0ceba808760a61b014f1a0bee9a22919ffdee6d4 Mon Sep 17 00:00:00 2001 From: Pavol Rusnak Date: Tue, 4 Feb 2020 16:37:20 +0000 Subject: [PATCH] legacy: fix wrong logic in layoutButtonNo --- legacy/firmware/stellar.c | 2 +- legacy/layout.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/legacy/firmware/stellar.c b/legacy/firmware/stellar.c index 948aabd4c..ae7498204 100644 --- a/legacy/firmware/stellar.c +++ b/legacy/firmware/stellar.c @@ -1792,7 +1792,7 @@ void stellar_layoutSigningDialog(const char *line1, const char *line2, offset_y += line_height; // Cancel button - layoutButtonNo("Cancel", &bmp_btn_cancel); + layoutButtonNo(_("Cancel"), &bmp_btn_cancel); // Warnings (drawn centered between the buttons if (warning) { diff --git a/legacy/layout.c b/legacy/layout.c index e5c235624..51c8bfefb 100644 --- a/legacy/layout.c +++ b/legacy/layout.c @@ -28,9 +28,9 @@ void layoutButtonNo(const char *btnNo, const BITMAP *icon) { oledDrawBitmap(1, OLED_HEIGHT - 8, icon); icon_width = icon->width; } - oledDrawString(8 + 3, OLED_HEIGHT - icon_width, btnNo, FONT_STANDARD); + oledDrawString(3 + icon_width, OLED_HEIGHT - 8, btnNo, FONT_STANDARD); oledInvert(0, OLED_HEIGHT - 9, - icon_width + oledStringWidth(btnNo, FONT_STANDARD) + 2, + icon_width + oledStringWidth(btnNo, FONT_STANDARD) + 4, OLED_HEIGHT - 1); }