I have a very simple use case. On the first activity (lets call it activity A), I have two buttons. One button for "sign UP" the user. The other button is for "sign IN". If the user taps on the "sign IN" button, then the username/password is form is presented. If the user successfully enters the username/password, then I don't want activity A anymore on the stack. On the other hand, if the user enters the wrong credentials on the "sign IN" screen, then I still want the user to be able to hit the back button and go back so I give the user an opportunity to "sign UP".
So the question is, from the "sign IN" screen, how can I finish activity A if the credentials entered are valid?
Put simply, root---(starts)--->A---(starts)---->B. Based on some event that occurs in activity B, I either need to keep or finish activity A. Is this possible?
So the question is, from the "sign IN" screen, how can I finish activity A if the credentials entered are valid?
Put simply, root---(starts)--->A---(starts)---->B. Based on some event that occurs in activity B, I either need to keep or finish activity A. Is this possible?