It was working fine, but at some point it started doing this weird thing that whenever I touched the back key on the screen while on the Main Activity, instead of writing in the log:
** Activity (main) Pause, UserClosed = true **, I noticed it was saying
UserClosed = false.
I searched the forum for any kind of similar situation without any luck. I even tried it on two different devices and an emulator with the same result.
So I backed up the whole folder and started going backwards removing code, libraries, files, manifest settings. At every step and run I cleaned up the project, just to be sure. I finally stopped when I got to a barebones, basic structure and the issue still persisted.
I can't seem to pinpoint where the issue started and if it can be fixed by any means different to importing my code (modules, files, layouts) into a new project hoping it will not happen again or just waiting to see if it happens again.
So I'm attaching a video showing the issue.
Has anyone encountered anything like this? And if so... how did you fix it?
Edit: The solution was to add the Activity_KeyPress event.