I am facing this issue:
- Create intent from an
Activity
- Then at Home screen, I call
startActivity
with this intent - After I
startActivity
with intent A then intent B, the intent A still remain behind
I want:
- free intent A when I
startActivity
with intent B - press BACK from any intents will back to Home screen
Please help me.
tvAbout = (TextView) mSettingsMenu.findViewById(R.id.tv_about);
tvAbout.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
Intent intent = new Intent(v.getContext(), AboutActivity.class);
activity.startActivity(intent);
mDrawerLayout.closeDrawer(Gravity.LEFT);
}
});
tvProfile = (TextView) mSettingsMenu.findViewById(R.id.tv_profile);
tvProfile.setOnClickListener(new OnClickListener() {
@Override
public void onClick(View v) {
Intent intent = new Intent(v.getContext(), ProfileActivity.class);
activity.startActivity(intent);
mDrawerLayout.closeDrawer(Gravity.LEFT);
}
});
...