I am trying to play a video on Android by running intention. The code I'm using is:
tostart = new Intent(Intent.ACTION_VIEW); tostart.setDataAndType(Uri.parse(movieurl), "video/*"); startActivity(tostart);
This works on most phones, but not on HTC Hero . It seems to be loading a slightly different video player. This is truly the first video thrown at him. However, each video after that does not respond. (he keeps in some cycle).
If I add explicit
tostart.setClassName("com.htc.album","com.htc.album.ViewVideo");
(before work) it works on HTC Hero . However, since this is a special HTC call, I cannot run this code on other phones (for example, G1 ). On G1, this works:
tostart.setClassName("com.android.camera","com.android.camera.MovieView");
But this intention is absent from the hero. Does anyone know a list of intentions / cool names that should be supported by all Android devices? Or specific to launch the video? Thank!
android android-intent sdk video
PanMan Oct. 15 '09 at 12:39 2009-10-15 12:39
source share