@Override
  public boolean onOptionsItemSelected(MenuItem item) {
    switch (item.getItemId()) {
      case android.R.id.home:
        this.onBackPressed();
        break;
    }
    return true;
  }
Called when the activity is first created
java/com/google/android/apps/authenticator/otp/EnterKeyActivity.java