Improve consistency of sound_play_effect

This commit is contained in:
Robin Jones 2024-10-25 15:09:12 +01:00
parent 6eb6991ca0
commit f5dd0ae336
11 changed files with 11 additions and 11 deletions

View File

@ -12,8 +12,8 @@
static void process (menu_t *menu) {
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -50,8 +50,8 @@ static char *format_file_type (char *name, bool is_directory) {
static void process (menu_t *menu) {
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -28,8 +28,8 @@ static const char *format_cart_type () {
static void process (menu_t *menu) {
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -38,8 +38,8 @@ static void process (menu_t *menu) {
load_rom = true;
sound_play_effect(SFX_SETTING);
} else if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -36,8 +36,8 @@ static void process (menu_t *menu) {
if (menu->actions.enter) {
load_pending = true;
} else if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -198,8 +198,8 @@ static void process (menu_t *menu) {
if (menu->actions.enter) {
load_pending = true;
} else if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
} else if (menu->actions.options) {
component_context_menu_show(&options_context_menu);
sound_play_effect(SFX_SETTING);

View File

@ -41,8 +41,8 @@ static void process (menu_t *menu) {
if (err != MP3PLAYER_OK) {
menu_show_error(menu, convert_error_message(err));
} else if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
} else if (menu->actions.enter) {
err = mp3player_toggle();
if (err != MP3PLAYER_OK) {

View File

@ -18,8 +18,8 @@
static void process (menu_t *menu) {
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -114,8 +114,8 @@ static void process (menu_t *menu) {
component_context_menu_show(&options_context_menu);
sound_play_effect(SFX_SETTING);
} else if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -28,8 +28,8 @@ static void process (menu_t *menu) {
}
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
}
}

View File

@ -55,8 +55,8 @@ static void perform_vertical_scroll (int lines) {
static void process (menu_t *menu) {
if (menu->actions.back) {
menu->next_mode = MENU_MODE_BROWSER;
sound_play_effect(SFX_EXIT);
menu->next_mode = MENU_MODE_BROWSER;
} else if (text) {
if (menu->actions.go_up) {
perform_vertical_scroll(menu->actions.go_fast ? -10 : -1);