CopyPastor

Detecting plagiarism made easy.

Score: 0.8074824213981628; Reported for: String similarity Open both answers

Possible Plagiarism

Plagiarized on 2018-11-29
by Manthan Patel

Original Post

Original - Posted on 2015-01-20
by Arunendra



            
Present in both answers; Present only in the new answer; Present only in the old answer;

>In oncreate(); write this line->
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
>then implement below method in that class
@Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case android.R.id.home: // app icon in action bar clicked; go home onBackPressed(); return true; default: return super.onOptionsItemSelected(item); } }
Firstly Use this:
> ActionBar bar = getSupportActionBar();
> bar.setDisplayHomeAsUpEnabled(true);
Then set operation of button click in onOptionsItemSelected method
@Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case android.R.id.home: finish(); return true; default: return super.onOptionsItemSelected(item); } }

        
Present in both answers; Present only in the new answer; Present only in the old answer;