diff --git a/apps/inheritance_app/inheritance_decrypt_data.c b/apps/inheritance_app/inheritance_decrypt_data.c index 6cc7630c8..ca6e3eda3 100644 --- a/apps/inheritance_app/inheritance_decrypt_data.c +++ b/apps/inheritance_app/inheritance_decrypt_data.c @@ -80,6 +80,7 @@ #include "status_api.h" #include "ui_core_confirm.h" #include "ui_screens.h" +#include "ui_state_machine.h" #include "utils.h" #include "wallet.h" #include "wallet_list.h" @@ -355,7 +356,7 @@ STATIC bool inheritance_decryption_handle_initiate_query( result.decrypt.which_response = INHERITANCE_DECRYPT_DATA_WITH_PIN_RESPONSE_CONFIRMATION_TAG; inheritance_send_result(&result); - delay_scr_init(ui_text_processing, DELAY_TIME); + delay_scr_init(ui_text_processing, DELAY_SHORT); return true; } @@ -608,7 +609,7 @@ static bool decrypt_data(void) { } } while (0); - delay_scr_init(ui_text_processing, DELAY_TIME); + delay_scr_init(ui_text_processing, DELAY_SHORT); return status; } @@ -620,9 +621,14 @@ static bool show_data(void) { uint8_t tag = decryption_context->data[i].plain_data[0]; if (tag == INHERITANCE_ONLY_SHOW_ON_DEVICE) { - message_scr_init( - (const char *)&decryption_context->data[i] - .plain_data[3]); ///< sizeof (tag) + sizeof (length) = 3 + char msg[100] = {0}; + snprintf(msg, + sizeof(msg), + UI_TEXT_PIN, ///< TODO: Make this generic + &decryption_context->data[i].plain_data[3]); + message_scr_init(msg); ///< sizeof (tag) + sizeof (length) = 3 + // Do not care about the return value from confirmation screen + (void)get_state_on_confirm_scr(0, 0, 0); } else { uint16_t offset = 1; // Skip tag decryption_context->response_payload.decrypted_data[response_count] @@ -661,10 +667,10 @@ decryption_error_type_e inheritance_decrypt_data(inheritance_query_t *query) { if (inheritance_decryption_handle_initiate_query(query) && inheritance_get_encrypted_data(query) && decrypt_data() && show_data() && send_decrypted_data(query)) { - delay_scr_init(ui_text_inheritance_decryption_flow_success, DELAY_TIME); + delay_scr_init(ui_text_inheritance_decryption_flow_success, DELAY_SHORT); SET_ERROR_TYPE(DECRYPTION_OK); } else { - delay_scr_init(ui_text_inheritance_decryption_flow_failure, DELAY_TIME); + delay_scr_init(ui_text_inheritance_decryption_flow_failure, DELAY_SHORT); } decryption_handle_errors(); diff --git a/src/constant_texts.h b/src/constant_texts.h index 42ec2a51f..cb582947f 100644 --- a/src/constant_texts.h +++ b/src/constant_texts.h @@ -53,7 +53,7 @@ #define UI_TEXT_BLIND_SIGNING_WARNING \ LV_SYMBOL_WARNING " Blind Signing\nProceed at your own risk!" #define UI_TEXT_VERIFY_HD_PATH "Verify Derivation Path" -#define UI_TEXT_PIN "PIN" +#define UI_TEXT_PIN "PIN\n %s" #define UI_TEXT_VERIFY_DESTINATION_TAG "Verify Destination Tag\n%lu" // product hash