爲什麼代碼中的原始文件夾有紅線,雖然我有這個文件夾! ?這段代碼的錯誤是什麼?
什麼是錯了嗎?
package com.example.second;
公共類奧馬爾延伸活動{
MediaPlayer song;
@Override
protected void onCreate(Bundle omar) {
// TODO Auto-generated method stub
super.onCreate(omar);
setContentView(R.layout.omar);
song = MediaPlayer.create(omar.this, R.raw.one);
song.start();
Thread timer = new Thread(){
public void run(){
try{
sleep(5000);
}catch(InterruptedException e){
e.printStackTrace();
}finally{
Intent open = new Intent("android.intent.action.MAIN");
startActivity(open);
}
}
};
timer.start();
}
@Override
protected void onPause() {
// TODO Auto-generated method stub
super.onPause();
song.release();
finish();
}
}
,什麼是最後的方法是什麼意思?
@Override
protected void onPause() {
// TODO Auto-generated method stub
super.onPause();
song.release();
finish();
}
好感謝所有,但我想任何一個向我解釋的最後一個方法:) –