How to open my custom video player when i click a you-tube link in android?
I have installed a video player in my Android box. Currently i am not able to play the you-tube videos in my browser. So i would like to open my player when the u开发者_如何学Pythonser clicks a you-tube link. Then the video will be played in my browser.
Please guide me with some pointers on how i can do this?
You can use this code on your click on code:
Intent intent = new Intent("android.intent.action.VIEW", Uri.parse(url));// url is your URL for YouTube video
view.getContext().startActivity(intent);
精彩评论