I have an Android app coded in Cocos2d-x. At launch, it often doesn't respond to any taps or presses until I press the back button.
Sometimes on app relaunch, the screen remains blank.
Any suggestions?
Related
I am working on the Kiosk mode in Android using the following link and would control the "onBackPressed" and "Switch App" icon.
http://www.andreas-schrade.de/2015/02/16/android-tutorial-how-to-create-a-kiosk-mode-in-android/
What I want
When users press the home button, the app will just "wake-up" or relaunch instead of the activity is closing down.
I am able to detech when home button is pressed and I ask the app to wakeup, but the app is still leaving when home button is pressed.
I have an android application, when user presses home or back key, android application will be minimized.
I want to open this application after pressing back or home key. (like long press in home key and selecting minimized app - I want application do this automatically).
What should I do? Please help me.
I guess what you need is Kiosk Mode.
it can disable Android features that can be used to leave your app. The following features are affected:
The back button
The home button
The recent apps button
The power button
The volume buttons
I have made an android app that runs successfully. But when back button is pressed it stops. My app is supposed to work even when back button is pressed.
How to do this?
and where to place this piece of code?
You should implement a router in your app. See ampersand-router for example. It will handle the "back" events of the browser.
I am making a parental control app.
The user can run other program from my app.
When they hit the home button and goes to the home screen, I want my app to detect it so that it can be redirected to my app.
How can I do this?
When some users click an ad on my app and they are done viewing the ad, and want to come back to the app, if they hit the back button the control goes to the home screen but the app does not crash because they see it running in the background.
I am not overwriting the default behavior of the controls.
What could be causing this or is it the expected behavior ?
This is not expected behaviour.
If they are definitely pressing the back button (and not the home button), then it sounds like the intent that displayed the Play Store has been configured to start the Activity in a new Task. Unfortunately, there isn't anything you can do do about this except raise it with the ad network in question.