Skip to content

Commit

Permalink
fix: fix the issue of briefly appearing on the app homepage after con…
Browse files Browse the repository at this point in the history
…firming the transaction. (#61)
  • Loading branch information
overcat authored Jul 23, 2024
1 parent 34fe77d commit a526178
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/ui/nbgl_address.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@
#include "action/validate.h"

static void review_choice(bool confirm) {
validate_pubkey(confirm);
if (confirm) {
nbgl_useCaseReviewStatus(STATUS_TYPE_ADDRESS_VERIFIED, ui_menu_main);
} else {
nbgl_useCaseReviewStatus(STATUS_TYPE_ADDRESS_REJECTED, ui_menu_main);
}
validate_pubkey(confirm);
}

int ui_display_address(void) {
Expand Down
4 changes: 2 additions & 2 deletions src/ui/nbgl_hash.c
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ static void prepare_page(void) {
}

static void reject_confirmation(void) {
ui_action_validate_transaction(false);
nbgl_useCaseStatus("Hash rejected", false, ui_menu_main);
ui_action_validate_transaction(false);
}

static void reject_choice(void) {
Expand All @@ -80,8 +80,8 @@ static void reject_choice(void) {

static void review_choice(bool confirm) {
if (confirm) {
ui_action_validate_transaction(true);
nbgl_useCaseStatus("Hash signed", true, ui_menu_main);
ui_action_validate_transaction(true);
} else {
reject_choice();
}
Expand Down
8 changes: 4 additions & 4 deletions src/ui/nbgl_transaction.c
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,8 @@ static bool display_transaction_page(uint8_t page, nbgl_pageContent_t *content)
}

static void reject_tx_confirmation(void) {
ui_action_validate_transaction(false);
nbgl_useCaseReviewStatus(STATUS_TYPE_TRANSACTION_REJECTED, ui_menu_main);
ui_action_validate_transaction(false);
}

static void reject_tx_choice(void) {
Expand All @@ -245,8 +245,8 @@ static void reject_tx_choice(void) {

static void review_tx_choice(bool confirm) {
if (confirm) {
ui_action_validate_transaction(true);
nbgl_useCaseReviewStatus(STATUS_TYPE_TRANSACTION_SIGNED, ui_menu_main);
ui_action_validate_transaction(true);
} else {
reject_tx_choice();
}
Expand All @@ -271,8 +271,8 @@ static void review_tx_start(void) {
}

static void reject_auth_confirmation(void) {
ui_action_validate_transaction(false);
nbgl_useCaseStatus("Soroban Auth rejected", false, ui_menu_main);
ui_action_validate_transaction(false);
}

static void reject_auth_choice(void) {
Expand All @@ -285,8 +285,8 @@ static void reject_auth_choice(void) {

static void review_auth_choice(bool confirm) {
if (confirm) {
ui_action_validate_transaction(true);
nbgl_useCaseStatus("Soroban Auth signed", true, ui_menu_main);
ui_action_validate_transaction(true);
} else {
reject_auth_choice();
}
Expand Down

0 comments on commit a526178

Please sign in to comment.