On an android App I made, whenever the user turns the app to the side, the app turns sideways and restarts (this was on the droid). I don't want to this to happen. I want the app to not restart when the device is turned sideways.
Also I would prefer the app to be locked in the vertical position.
How would I go about this two thing?
Thanks in advance.
This has been covered numerous times Android, how to not destroy the activity when I rotate the device?
Related
I'm developing a game in AS3 for Android. For some reason when I'm testing it on an Android device, after, lets say, 3 or 4 seconds, the screens starts to fade out till it's completely black while app is still running.
I have the "Stay Active/Awake" on "Android Developers Option".
I'm hoping you can help me with this problem.
Thank you!
As I'm using only Accelerometer it doesn't count as a feature to stay awake. We have to force Android to stay awake by code. Basically when app is running it triggers stayAwake mode else it triggers normal mode.
I have a problem that I don't really know how to solve and also the threads here at SO haven't fully helped me.
Here's the issue: I want to have an android app that I can start whenever I want, and then, when I click on a button, I want the app to be somewhat "locked". By that I mean: after this button was pressed, the user is not able to close(see edit below) the app. Also, the app should immediately start after rebooting the device.
This lock can then be revoked by, say, entering a passcode, which makes the app run normally again.
So far I understand how to build kiosk applications. However, a kiosk application needs a particular manifest which will make it always a kiosk app, and not "on demand".
I'd greatly appreciate any hints and tips on this topic. Thank you so much!
EDIT: by "close" I really only mean completely turning the app off, not only going back to your home screen. Such that the app is always running in the background
You can programmatically lock and unlock the App in Android 5.0 http://developer.android.com/about/versions/android-5.0.html#ScreenPinning
We have designed an hybrid app which is a bit heavy (9 MB). Problem is that at times, minimizing this app (home button) makes the app reset in background i.e. its app cache is lost and app reloads from splash screen. After minimizing we worked with other apps in tablet (Galaxy 800).
We saw this problem only if we tried to launch app from the icon in launcher. This problem did not happen when we tried to launch it from the minimized list(recent apps button).
This problem is not specific to the tab. It also happened in Galaxy 3 and Droid Razr also.
Any guidance?
Problem is that at times, minimizing this app (home button) makes the app reset in background i.e. its app cache is lost and app reloads from splash screen.
This is perfectly normal.
Computers, phones, and tablets do not have infinite RAM. Android's approach to this problem is to keep your process around for a while after the user has left it, but eventually Android will terminate your process to free up RAM for other applications and their processes. You can read more about the Android process model in the documentation.
It can be possible that ‘deep clean' option is enabled by mistake on your phone. What deep clean does is, whenever you minimize an app , it releases all the memory associated with that app, and hence when you again open that app, it will start as if it is new. To check the 'deep clean' option,
go to the
Developer options -> 'Don't keep activities' -> disable it
If it is not disable please disable it.
i have a Phonegap and JQM app.
Problem is, if I switch to another app and then back to my app, App is completely reloaded and start again.
Is posible this disable?
Thanks for any advice.
This is happening because there is a lack of memory for the app to run. So as soon as u go to home the app dies and on opening again it reloads the app from the start. To confirm that this is indeed happening i would suggest that you close all running apps on your phone and then run your app. Im sure it would run properly even after switching to home screen and coming back.I don't think its possible to get around this behavior. Design your app so that it has a small startup time so that its usable even on phones with less ram where such problems would come.
This is the second time this has happened to me now. I changed the starting activity of my app, and put out an update, and now the icon on people's phone will not open my app. The only way they can open it is through the downloads section of their Android Market app, or if they uninstall and reinstall the app, causing them to lose ALL their data.
I have no problem with updates on my N1, but every other Android phone has a problem with this. Why?
The only way they can open it is
through the downloads section of their
Android Market app, or if they
uninstall and reinstall the app,
causing them to lose ALL their data.
Powering their phone off and on should work as well.
I have no problem with updates on my
N1, but every other Android phone has
a problem with this. Why?
It's a question of when the home screen app elects to reload its launcher data. Different home screen implementations handle this differently. You will have the same problem with any user-created shortcuts and the like.