package com.bob.digcsdn; import android.app.Activity; import android.os.Bundle; import android.view.MenuItem; import android.view.View; import android.widget.LinearLayout; import android.widget.TextView; import com.bob.digcsdn.R; /** * Created by bob on 15-4-27. * 侧滑退出会有白屏延迟,如果做成fragment,侧边栏菜单只是一个辅助类菜单,不应该 */ public class AboutActivity extends BaseActivity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState ); setContentView(R.layout.activity_about, true, R.id.toolbar); getSupportActionBar().setTitle("关于"); getSupportActionBar().setDisplayHomeAsUpEnabled(true); } @Override public boolean onOptionsItemSelected(final MenuItem item) { switch (item.getItemId()) { case android.R.id.home: finish(); break; } return true; } }