I have an app that plays videos from public sites through a VideoView
inside a WebView. I need the VideoView object to get the video Uri to
store. Before ICS the following code used to work fine.
@Overridepublic void onShowCustomView(final View view, final
CustomViewCallback callback) {
super.onShowCustomView(view, callback);
if (view instanceof FrameLayout) {
final FrameLayout frame = (FrameLayout) view;
if (frame.getFocusedChild() instanceof VideoView) {
// get video view
video = (VideoView) frame.getFocusedChild();
}
}}
Now unfortunately in ICS whenever a video is played inline (i.e. not in
fullscreen mode) the onShwoCustomView is not called
This is documented here http://code.google.com/p/android/issues/detail?id=36020
Now I am searching high and low for an alternative to get a callback when the
video is playing inline.
I checked the HTML5VideoViewProxy.java and HTML5VideoView.java and found that
onShwoCustomView is called only from HTML5FullScreenVideo.java
I am now totally at a loss on how to proceed.
If I can manage to get a callback when the video starts paying then I can at
least try and get the path Uri maybe through reflection.
Also searching around somebody suggested that a *JNI plugin can be registered
to get the video playback event*.
I don't have much idea on this can anybody validate if it is possible to get
the video uri path using JNI?
Is there any other work around?
Any help appreciated
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en