Android Question how to stop background playing of video

surfer

Member
Licensed User
I need help.

I build an app with 2 activities:
1-st activity contains ListVew1 with list of Youtube videos names.
2-nd activity contains WebView.
And when I touch an item in ListView I start second activity and show in Webview HTML page with <iframe> code embedding corresponding video.

I start the video and in it’s middle I press BACK key. So I return to the list in the first activity. But I still hear some time the video playing in background. And that is the reason of rejecting this application by Google Play.

My question: How can I prevent the background playing of the video immediately after pressing BACK key?
Please help.
 
Top