From 15e6d224e5a3e66f56a1fba09d48048e622c384d Mon Sep 17 00:00:00 2001 From: Francois Beutin Date: Thu, 26 Oct 2023 12:15:44 +0200 Subject: [PATCH] Rename boilerplate_plugin.h into generic plugin.h --- src/handle_finalize.c | 2 +- src/handle_init_contract.c | 2 +- src/handle_provide_parameter.c | 2 +- src/handle_provide_token.c | 2 +- src/handle_query_contract_id.c | 2 +- src/handle_query_contract_ui.c | 2 +- src/{boilerplate_plugin.c => plugin.c} | 2 +- src/{boilerplate_plugin.h => plugin.h} | 0 8 files changed, 7 insertions(+), 7 deletions(-) rename src/{boilerplate_plugin.c => plugin.c} (96%) rename src/{boilerplate_plugin.h => plugin.h} (100%) diff --git a/src/handle_finalize.c b/src/handle_finalize.c index f6ba228e..eb01e6ea 100644 --- a/src/handle_finalize.c +++ b/src/handle_finalize.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" void handle_finalize(void *parameters) { ethPluginFinalize_t *msg = (ethPluginFinalize_t *) parameters; diff --git a/src/handle_init_contract.c b/src/handle_init_contract.c index 77728ab8..331d854e 100644 --- a/src/handle_init_contract.c +++ b/src/handle_init_contract.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" #include "utils.h" // Called once to init. diff --git a/src/handle_provide_parameter.c b/src/handle_provide_parameter.c index f51a0061..b34e2926 100644 --- a/src/handle_provide_parameter.c +++ b/src/handle_provide_parameter.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" // EDIT THIS: Remove this function and write your own handlers! static void handle_swap_exact_eth_for_tokens(ethPluginProvideParameter_t *msg, context_t *context) { diff --git a/src/handle_provide_token.c b/src/handle_provide_token.c index 5e688505..b7e53979 100644 --- a/src/handle_provide_token.c +++ b/src/handle_provide_token.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" // EDIT THIS: Adapt this function to your needs! Remember, the information for tokens are held in // `msg->token1` and `msg->token2`. If those pointers are `NULL`, this means the ethereum app didn't diff --git a/src/handle_query_contract_id.c b/src/handle_query_contract_id.c index a4588129..8c52902e 100644 --- a/src/handle_query_contract_id.c +++ b/src/handle_query_contract_id.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" // Sets the first screen to display. void handle_query_contract_id(ethQueryContractID_t *msg) { diff --git a/src/handle_query_contract_ui.c b/src/handle_query_contract_ui.c index dc9b0f77..6d2b8b49 100644 --- a/src/handle_query_contract_ui.c +++ b/src/handle_query_contract_ui.c @@ -1,4 +1,4 @@ -#include "boilerplate_plugin.h" +#include "plugin.h" // EDIT THIS: You need to adapt / remove the static functions (set_send_ui, set_receive_ui ...) to // match what you wish to display. diff --git a/src/boilerplate_plugin.c b/src/plugin.c similarity index 96% rename from src/boilerplate_plugin.c rename to src/plugin.c index 14d80cbf..cad5461a 100644 --- a/src/boilerplate_plugin.c +++ b/src/plugin.c @@ -16,7 +16,7 @@ ********************************************************************************/ #include -#include "boilerplate_plugin.h" +#include "plugin.h" // This array will be automatically expanded to map all selector_t names with the correct value. // Do not modify ! diff --git a/src/boilerplate_plugin.h b/src/plugin.h similarity index 100% rename from src/boilerplate_plugin.h rename to src/plugin.h