[Android] Listen to MetaData changes
Alexandre Perraud
git at videolan.org
Tue Nov 25 11:39:03 CET 2014
vlc-ports/android | branch: master | Alexandre Perraud <4leyx4ndre at gmail.com> | Mon Nov 24 18:34:23 2014 +0100| [4fb8f3bbfd3dcae4c103ed2b4b08e9d84963feb0] | committer: Jean-Baptiste Kempf
Listen to MetaData changes
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=4fb8f3bbfd3dcae4c103ed2b4b08e9d84963feb0
---
libvlc/jni/libvlcjni.c | 3 ++-
libvlc/src/org/videolan/libvlc/EventHandler.java | 2 +-
2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/libvlc/jni/libvlcjni.c b/libvlc/jni/libvlcjni.c
index 3fab373..ccba63c 100644
--- a/libvlc/jni/libvlcjni.c
+++ b/libvlc/jni/libvlcjni.c
@@ -454,7 +454,8 @@ void Java_org_videolan_libvlc_LibVLC_playMRL(JNIEnv *env, jobject thiz, jlong in
/* Connect the media event manager. */
libvlc_event_manager_t *ev_media = libvlc_media_event_manager(p_md);
static const libvlc_event_type_t mp_media_events[] = {
- libvlc_MediaParsedChanged
+ libvlc_MediaParsedChanged,
+ libvlc_MediaMetaChanged,
};
for(int i = 0; i < (sizeof(mp_media_events) / sizeof(*mp_media_events)); i++)
libvlc_event_attach(ev_media, mp_media_events[i], vlc_event_callback, myVm);
diff --git a/libvlc/src/org/videolan/libvlc/EventHandler.java b/libvlc/src/org/videolan/libvlc/EventHandler.java
index 16a0791..4ec0861 100644
--- a/libvlc/src/org/videolan/libvlc/EventHandler.java
+++ b/libvlc/src/org/videolan/libvlc/EventHandler.java
@@ -32,7 +32,7 @@ public class EventHandler {
* Be sure to subscribe to events you need in the JNI too.
*/
- //public static final int MediaMetaChanged = 0;
+ public static final int MediaMetaChanged = 0;
//public static final int MediaSubItemAdded = 1;
//public static final int MediaDurationChanged = 2;
public static final int MediaParsedChanged = 3;
More information about the Android
mailing list