I was wondering if there is a way to ensure a user actually wants to leave an app. For instance, I figured out the back button using KeyCodes. However, it seems that this is not available for either the home or the overview buttons.
B4X:
Sub Activity_KeyPress (KeyCode As Int) As Boolean
If KeyCode = KeyCodes.KEYCODE_BACK Then
Select Msgbox2Async("Are you sure you want to exit?","WARNING","Yes","No","",Null,False)
Case DialogResponse.POSITIVE
Activity.Finish
Case Else
Return True
End Select
End If
End Sub
I then checked this page to see if I could find anything.