title: Finishing current activity from a fragment
body: <p>I have a fragment in an activity that I am using as a navigation drawer.  It contains buttons that when clicked start new activities (startActivity from a fragment simply calls startActivity on the current activity).</p>
  
  <p>For the life of me I can't seem to figure out how I would finish the current activity after starting a new one.</p>
  
  <p>I am looking to achieve something like this in the fragment:</p>
  
  <pre><code>@Override
  public void onClick(View view) {
      // TODO Auto-generated method stub
      if (view == mButtonShows) {
          Intent intent = new Intent(view.getContext(), MyNewActivity.class);
          intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
          startActivity(intent);
          finish();
      } 
  }
  </code></pre>
  
  <p>But it seems Fragment.class does not implement finish() (like it implements startActivity(...)).</p>
  
  <p>I would like the activity backstack cleared when they launch the 2nd activity. (so pressing back from the new activity would technically drop them back to the launcher)</p>