summaryrefslogtreecommitdiff
path: root/apps/hosted/android/notification.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/hosted/android/notification.c')
-rw-r--r--apps/hosted/android/notification.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/apps/hosted/android/notification.c b/apps/hosted/android/notification.c
index 874cd3bcef..66715d26f9 100644
--- a/apps/hosted/android/notification.c
+++ b/apps/hosted/android/notification.c
@@ -44,8 +44,9 @@ static const struct dim dim = { .width = 200, .height = 200 };
44 44
45/* 45/*
46 * notify about track change, and show track info */ 46 * notify about track change, and show track info */
47static void track_changed_callback(void *param) 47static void track_changed_callback(unsigned short id, void *param)
48{ 48{
49 (void)id;
49 struct mp3entry* id3 = ((struct track_event *)param)->id3; 50 struct mp3entry* id3 = ((struct track_event *)param)->id3;
50 JNIEnv e = *env_ptr; 51 JNIEnv e = *env_ptr;
51 if (id3) 52 if (id3)
@@ -106,8 +107,9 @@ static void track_changed_callback(void *param)
106 107
107/* 108/*
108 * notify about track finishing */ 109 * notify about track finishing */
109static void track_finished_callback(void *param) 110static void track_finished_callback(unsigned short id, void *param)
110{ 111{
112 (void)id;
111 if (((struct track_event *)param)->flags & TEF_REWIND) 113 if (((struct track_event *)param)->flags & TEF_REWIND)
112 return; /* Not a true track end */ 114 return; /* Not a true track end */
113 115
@@ -144,6 +146,6 @@ void notification_init(void)
144 finishNotification = e->GetMethodID(env_ptr, class, "finishNotification", 146 finishNotification = e->GetMethodID(env_ptr, class, "finishNotification",
145 "()V"); 147 "()V");
146 148
147 add_event(PLAYBACK_EVENT_TRACK_CHANGE, false, track_changed_callback); 149 add_event(PLAYBACK_EVENT_TRACK_CHANGE track_changed_callback);
148 add_event(PLAYBACK_EVENT_TRACK_FINISH, false, track_finished_callback); 150 add_event(PLAYBACK_EVENT_TRACK_FINISH track_finished_callback);
149} 151}