package com.shamanland.fab.example; import android.app.ActionBar; import android.app.Activity; import android.os.Build; import android.os.Bundle; import android.view.MenuItem; public class ExampleDetailsActivity extends Activity { @Override protected void onCreate(Bundle state) { super.onCreate(state); setContentView(R.layout.a_example_details); if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB) { ActionBar ab = getActionBar(); if (ab != null) { ab.setDisplayHomeAsUpEnabled(true); } } } @Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case android.R.id.home: finish(); break; } return super.onOptionsItemSelected(item); } }