Ejemplo n.º 1
0
 @Override
 public boolean onOptionsItemSelected(MenuItem item) {
   switch (item.getItemId()) {
     case android.R.id.home:
       AppUtils.navigateUp(this);
       return true;
     default:
       return super.onOptionsItemSelected(item);
   }
 }
Ejemplo n.º 2
0
  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

    AppUtils.setupActionBarDisplayUp(this);

    setContentView(R.layout.pattern_lock_activity);

    if (savedInstanceState != null) {
      confirmStarted = savedInstanceState.getBoolean(KEY_CONFIRM_STARTED);
    }
    if (!confirmStarted) {
      PatternLockUtils.confirmPatternIfHas(this);
      confirmStarted = true;
    }
  }