@Override
    public boolean onSupportNavigateUp() {
        onBackPressed();
        return true;
    }
Sample Activity extending from ActionBarActivity to display a Toolbar.
sample/src/main/java/example/zxing/ToolbarCaptureActivity.java