DJUI: Added sounds to popups

This commit is contained in:
MysterD 2021-07-30 18:22:32 -07:00
parent 4e0a3e3e57
commit d615dcfbce
1 changed files with 4 additions and 0 deletions

View File

@ -1,5 +1,7 @@
#include <time.h> #include <time.h>
#include "djui.h" #include "djui.h"
#include "audio_defines.h"
#include "audio/external.h"
#include "pc/network/network.h" #include "pc/network/network.h"
#include "pc/utils/misc.h" #include "pc/utils/misc.h"
@ -54,6 +56,7 @@ struct DjuiPopup* djui_popup_create(const char* message, int lines) {
sPopupListY -= height + 4; sPopupListY -= height + 4;
djui_popup_add_to_list(popup); djui_popup_add_to_list(popup);
play_sound(SOUND_MENU_MESSAGE_APPEAR, gDefaultSoundArgs);
return popup; return popup;
} }
@ -85,6 +88,7 @@ void djui_popup_update(void) {
djui_base_destroy(&node->popup->base); djui_base_destroy(&node->popup->base);
free(node); free(node);
node = next; node = next;
play_sound(SOUND_MENU_MESSAGE_DISAPPEAR, gDefaultSoundArgs);
continue; continue;
} }
} else { } else {