i want to show the progress dialog before playing video. i tried below link example for playing video.
http://davanum.wordpress.com/2009/12/04/android-%E2%80%93-videomus
I would suggest looking at the AsyncTask documentation, this seems ideally suited for doing video pre-loading. This will allow you to keep your UI thread stable during loading. There is an example of using the AsyncTask method here.
To add a progress dialog:
onPreExecute()
method you can perform progress dialog setting
up, such as:
pd.setMessage(...) pd.setTitle(...) pd.show(...)
onPostExecute(...)
method, dismiss the dialog: pd.dismiss();
Additionally, you can update the progress dialog using its incrementProgressBy(...)
method, or alternately have a looping animation using the setIndeterminate(...)
method. Giving the user feedback of the loaded progress is a good idea in UI design :)
I hope this helps!