From 5ab34a830373295cb7e32393b35bd21b3cf4bcc2 Mon Sep 17 00:00:00 2001 From: Vincent-FK Date: Sat, 15 May 2021 22:39:18 +0200 Subject: [PATCH] change for new notif script Signed-off-by: Vincent-FK --- input.c | 12 ++++++------ main.c | 2 +- menu.c | 6 +++--- menu.h | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/input.c b/input.c index 70d5a6bb..a8d09be2 100644 --- a/input.c +++ b/input.c @@ -825,7 +825,7 @@ u32 update_input() /*sprintf(hud_msg, "SAVED IN SLOT %d", savestate_slot); set_hud_msg(hud_msg, 4);*/ sprintf(shell_cmd, "%s %d \" SAVED IN SLOT %d\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, savestate_slot+1); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, savestate_slot+1); fp = popen(shell_cmd, "r"); if (fp == NULL) { printf("Failed to run command %s\n", shell_cmd); @@ -847,7 +847,7 @@ u32 update_input() /*sprintf(hud_msg, "LOADED FROM SLOT %d", savestate_slot); set_hud_msg(hud_msg, 4);*/ sprintf(shell_cmd, "%s %d \" LOADED FROM SLOT %d\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, savestate_slot+1); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, savestate_slot+1); fp = popen(shell_cmd, "r"); if (fp == NULL) { printf("Failed to run command %s\n", shell_cmd); @@ -951,7 +951,7 @@ u32 update_input() /*sprintf(hud_msg, " DISP MODE: ZOOMED %d%%", aspect_ratio_factor_percent); set_hud_msg(hud_msg, 4);*/ sprintf(shell_cmd, "%s %d \" DISPLAY MODE: ZOOMED %d%%%%\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); fp = popen(shell_cmd, "r"); if (fp == NULL) { printf("Failed to run command %s\n", shell_cmd); @@ -977,7 +977,7 @@ u32 update_input() /*sprintf(hud_msg, " DISP MODE: ZOOMED %d%%", aspect_ratio_factor_percent); set_hud_msg(hud_msg, 4);*/ sprintf(shell_cmd, "%s %d \" DISPLAY MODE: ZOOMED %d%%%%\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); fp = popen(shell_cmd, "r"); if (fp == NULL) { printf("Failed to run command %s\n", shell_cmd); @@ -998,12 +998,12 @@ u32 update_input() if(aspect_ratio == ASPECT_RATIOS_TYPE_MANUAL){ //sprintf(hud_msg, " DISP MODE: ZOOMED %d%%", aspect_ratio_factor_percent); sprintf(shell_cmd, "%s %d \" DISPLAY MODE: ZOOMED %d%%%%\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, aspect_ratio_factor_percent); } else{ //sprintf(hud_msg, "DISPLAY MODE: %s", aspect_ratio_name[aspect_ratio]); sprintf(shell_cmd, "%s %d \" DISPLAY MODE: %s\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, aspect_ratio_name[aspect_ratio]); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, aspect_ratio_name[aspect_ratio]); } //set_hud_msg(hud_msg, 4); fp = popen(shell_cmd, "r"); diff --git a/main.c b/main.c index d49bfffb..1b3f493c 100644 --- a/main.c +++ b/main.c @@ -469,7 +469,7 @@ int main(int argc, char *argv[]) /** Set notif for BIOS */ char shell_cmd[400]; sprintf(shell_cmd, "%s 0 \" BIOS FILE MISSING^^Connect your FunKey S to ^your computer and copy the^BIOS file to the folder:^ Game Boy Advance/bios/^^The file must be called:^gba_bios.bin^Size=16384 Bytes^MD5=a860e8c0b6d573d191e4ec7d^b1b1e4f6^^For more instructions:^www.funkey-project.com^^Press any button to exit...\"", - SHELL_CMD_NOTIF); + SHELL_CMD_NOTIF_SET); system(shell_cmd); while(gui_action == CURSOR_NONE) diff --git a/menu.c b/menu.c index ac35f4a3..654fba93 100644 --- a/menu.c +++ b/menu.c @@ -852,7 +852,7 @@ void run_menu_loop() /// ----- Hud Msg ----- sprintf(shell_cmd, "%s %d \" SAVED IN SLOT %d\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, savestate_slot+1); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, savestate_slot+1); system(shell_cmd); stop_menu_loop = 1; } @@ -881,11 +881,11 @@ void run_menu_loop() /// ----- Hud Msg ----- if(quick_load_slot_chosen){ sprintf(shell_cmd, "%s %d \" LOADED FROM AUTO SAVE\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP); } else{ sprintf(shell_cmd, "%s %d \" LOADED FROM SLOT %d\"", - SHELL_CMD_NOTIF, NOTIF_SECONDS_DISP, savestate_slot+1); + SHELL_CMD_NOTIF_SET, NOTIF_SECONDS_DISP, savestate_slot+1); } system(shell_cmd); stop_menu_loop = 1; diff --git a/menu.h b/menu.h index 1a80b2a3..1456fa01 100644 --- a/menu.h +++ b/menu.h @@ -40,8 +40,8 @@ typedef enum {RESUME_OPTIONS} ENUM_RESUME_OPTIONS; #define SHELL_CMD_VOLUME_SET "volume set" #define SHELL_CMD_BRIGHTNESS_GET "brightness get" #define SHELL_CMD_BRIGHTNESS_SET "brightness set" -#define SHELL_CMD_NOTIF "notif_set" -#define SHELL_CMD_NOTIF_CLEAR "notif_clear" +#define SHELL_CMD_NOTIF_SET "notif set" +#define SHELL_CMD_NOTIF_CLEAR "notif clear" #define SHELL_CMD_AUDIO_AMP_ON "audio_amp on" #define SHELL_CMD_AUDIO_AMP_OFF "audio_amp off" #define SHELL_CMD_CANCEL_SCHED_POWERDOWN "cancel_sched_powerdown"