|
|
package net.micode.notes.ui;
|
|
|
|
|
|
import android.content.Intent;
|
|
|
import android.support.v7.app.AppCompatActivity;
|
|
|
import android.os.Bundle;
|
|
|
import android.os.Handler;
|
|
|
|
|
|
import android.content.Intent;
|
|
|
import android.support.v7.app.AppCompatActivity;
|
|
|
import android.os.Bundle;
|
|
|
import android.os.Handler;
|
|
|
import net.micode .notes.R;
|
|
|
|
|
|
|
|
|
import net.micode.notes.databinding.ActivitySplashBinding;
|
|
|
import net.micode.notes.R;
|
|
|
|
|
|
|
|
|
/**
|
|
|
* @projectName(项目名称): xiaomi label
|
|
|
* @package(包): ui
|
|
|
* @className(类名称): type_name
|
|
|
* @description(类描述): 欢迎界面
|
|
|
* @author(创建人): zhangchaoqun
|
|
|
* @createDate(创建时间): datetime
|
|
|
* @updateUser(修改人): user
|
|
|
* @updateDate(修改时间): datetime
|
|
|
* @updateRemark(修改备注): 说明本次修改内容
|
|
|
* @version(版本): v1.0
|
|
|
*/
|
|
|
public class SplashActivity extends AppCompatActivity {
|
|
|
Handler mHandler=new Handler();
|
|
|
@Override
|
|
|
protected void onCreate(Bundle savedInstanceState) {
|
|
|
super.onCreate(savedInstanceState); //加载启动界面
|
|
|
setContentView(R.layout.activity_splash); //加载启动图片
|
|
|
|
|
|
// 当计时结束时,跳转至NotesListActivity
|
|
|
mHandler.postDelayed(new Runnable() {
|
|
|
@Override
|
|
|
public void run() {
|
|
|
Intent intent=new Intent();
|
|
|
intent.setClass(SplashActivity.this, NotesListActivity.class);
|
|
|
startActivity(intent);
|
|
|
finish(); //销毁欢迎页面
|
|
|
}
|
|
|
}, 1000); // 1秒后跳转
|
|
|
}
|
|
|
} |