解决方法@H_301_8@
或者你可以使用进度对话框
public class VideoEkrani extends Activity {
VideoView ekran;
String kaynakYolu = "http://commonsware.com/misc/test2.3gp";
ProgressDialog progDailog;
@Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.sayfa_video_goruntule);
ekran = (VideoView) findViewById(R.id.videoViewESPU);
ekran.setMediaController(new MediaController(this));
ekran.setVideoURI(Uri.parse(kaynakYolu));
ekran.requestFocus();
ekran.start();
progDailog = ProgressDialog.show(this,"Please wait ...","Retrieving data ...",true);
ekran.setOnPreparedListener(new OnPreparedListener() {
public void onPrepared(MediaPlayer mp) {
// TODO Auto-generated method stub
progDailog.dismiss();
}
});
}
}
public class VideoEkrani extends Activity { VideoView ekran; String kaynakYolu = "http://commonsware.com/misc/test2.3gp"; ProgressDialog progDailog; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.sayfa_video_goruntule); ekran = (VideoView) findViewById(R.id.videoViewESPU); ekran.setMediaController(new MediaController(this)); ekran.setVideoURI(Uri.parse(kaynakYolu)); ekran.requestFocus(); ekran.start(); progDailog = ProgressDialog.show(this,"Please wait ...","Retrieving data ...",true); ekran.setOnPreparedListener(new OnPreparedListener() { public void onPrepared(MediaPlayer mp) { // TODO Auto-generated method stub progDailog.dismiss(); } }); } }