Bug? Activity.Finish - 2nd Activity Exits App

JohnD

Active Member
Licensed User
Longtime User
If you use Activity.Finish 1 activity removed from main things behave as you would expect. However, when you use the backkey from the activity before you issued the Activity.Finish from, it exits you from the app entirely.

[Case 1 (desired behavior)]: Main calls StartActivity("A"). Activity("A") calls Activity.Finish after starting a new activity, Activity("B"). The backkey brings you to Main from Activity("B") because Activity("A") is gone. The backkey exits the app from Main.

[Case 2]: Main calls StartActivity("A") there is no call to Activity.Finish in this iteration of Activity("A"). Activity("A") calls StartActivity("B"). Activity("B") calls StartActivity("C") then Activity.Finish. Backkey from Activity("C") brings me to Main because Activity("B") is gone. Hmmm I thought maybe I'd go back to Activity("A"). Backkey from main brings me to Activity("A") - unexpected, I wanted to exit app from Main. BackKey from Activity("A") exits app. No Activity_Keypress processing in any of the activities.

Also, [Case 2] only happens with a Release version. It does not happen with a Debug version.
 
Last edited:

JohnD

Active Member
Licensed User
Longtime User
Erel: I have a solution for my project and have already implemented it. I think my solution fits the Android navigation model better as well. However if you would like me to post something recreating it, I'm fairly sure that I can. I just don't want to post my entire (data driven) project along with the password string for SQL Cipher.
 
Top