Suppose I have an Activity named ActivityA
and another Activity named ActivityB
. In each one I have a button that opens another Activity when it is clicked. I want to do following work when button is clicked:
check if there is an existing type of the target Activity in the activity back-stack or not, if there is, bring that Activity to the top and if not create new Intent and then go to that Activity.
How can I implement this?
Thanks.