Remove useless functions
This commit is contained in:
committed by
Alexandre Paillier
parent
ddc70a7bf2
commit
b7af62dc13
@@ -1,45 +1,5 @@
|
||||
#include "ui_nbgl.h"
|
||||
#include "ui_signing.h"
|
||||
#include "ui_logic.h"
|
||||
#include "ui_message_signing.h"
|
||||
#include "glyphs.h"
|
||||
|
||||
static void (*g_approved_func)(void) = NULL;
|
||||
static void (*g_rejected_func)(void) = NULL;
|
||||
|
||||
static void ui_message_rejection_handler() {
|
||||
nbgl_useCaseStatus("Message signing\ncancelled", false, g_rejected_func);
|
||||
}
|
||||
|
||||
static void ui_message_confirm_rejection(void) {
|
||||
nbgl_useCaseConfirm(REJECT_QUESTION(TEXT_MESSAGE),
|
||||
NULL,
|
||||
REJECT_CONFIRM_BUTTON,
|
||||
RESUME(TEXT_MESSAGE),
|
||||
ui_message_rejection_handler);
|
||||
}
|
||||
|
||||
void ui_message_review_choice(bool confirm) {
|
||||
if (confirm) {
|
||||
nbgl_useCaseStatus("MESSAGE\nSIGNED", true, g_approved_func);
|
||||
} else {
|
||||
ui_message_confirm_rejection();
|
||||
}
|
||||
}
|
||||
|
||||
void ui_message_start(const char *title,
|
||||
void (*start_func)(void),
|
||||
void (*approved_func)(void),
|
||||
void (*rejected_func)(void)) {
|
||||
g_approved_func = approved_func;
|
||||
g_rejected_func = rejected_func;
|
||||
nbgl_useCaseReviewStart(&C_Review_64px,
|
||||
title,
|
||||
NULL,
|
||||
REJECT_BUTTON,
|
||||
start_func,
|
||||
ui_message_confirm_rejection);
|
||||
}
|
||||
|
||||
static void ui_message_712_approved(void) {
|
||||
ui_712_approve();
|
||||
|
||||
@@ -9,11 +9,6 @@
|
||||
#define TEXT_REVIEW_EIP712 REVIEW(TEXT_TYPED_MESSAGE)
|
||||
#define TEXT_SIGN_EIP712 SIGN(TEXT_TYPED_MESSAGE)
|
||||
|
||||
void ui_message_review_choice(bool confirm);
|
||||
void ui_message_start(const char *title,
|
||||
void (*start_func)(void),
|
||||
void (*approved_func)(void),
|
||||
void (*rejected_func)(void));
|
||||
void ui_typed_message_review_choice(bool confirm);
|
||||
|
||||
#endif // UI_MESSAGE_SIGNING_H_
|
||||
|
||||
Reference in New Issue
Block a user