[
https://issues.apache.org/jira/browse/CB-1458?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13669139#comment-13669139
]
Francois Masurel commented on CB-1458:
--------------------------------------
In fact, it should be clearly specified that, in low memory conditions,
PhoneGap/Cordova just doesn't work on Android if you need to use external
activities like the phone Camera app.
We have spent weeks developping our mobile app using PhoneGap just to realize
at the end that the use of the Camera plugin crashes the app almost everytime.
We didn't hit the problem at the beginning because our dev phones where only
used for testing and had plenty of memory available.
But once tested on real users phones, we found that, for most of them, our
mobile app was crashing when using the camera. We had to modify the Cordova
core to save and restore the webview state and do the same for the Camera
plugin to "fix" the problem.
But we still have some problem with the webview history which doesn't seem to
be saved and restored properly, at least our app doesn't crash anymore and the
pictures taken are not lost definitely.
It should also be interesting to have an internal PhoneGap Camera plugin like
the foreground-camera-plugin but that's another point.
@Joe Bowser When will be released the PhoneGap version allowing to preserve
state? Thanx for your answer.
> Android's new "Limit background processes" setting in "Developer options"
> breaks key PhoneGap functionality.
> ------------------------------------------------------------------------------------------------------------
>
> Key: CB-1458
> URL: https://issues.apache.org/jira/browse/CB-1458
> Project: Apache Cordova
> Issue Type: Bug
> Components: Android, CordovaJS
> Environment: Android 4.x.x
> Reporter: trusktr
> Assignee: Joe Bowser
> Priority: Minor
>
> As of version 4.x.x, Android introduced a new ability to limit background
> processes down to zero in Settings >> Developer Options >> Limit background
> processes.
> I'm not sure if this bug exists with the latest PhoneGap version, but I
> noticed it using PhoneGap apps for android from Google Play.
> After setting the option to "No background processes" I noticed the
> following. If I try to use the Media abilities of PhoneGap in an app to chose
> a photo or file from my system, then when the selector application returns,
> the PhoneGap app will restart from the beginning because it's background
> process was terminated.
> If I set the option back to "Standard limit" then everything works just fine.
> What do we do about this? Personally, I prefer to have the option set to "No
> background processes" to prevent apps from needlessly wasting resources. It
> works great and some apps won't get terminated if they subscribe to Android's
> messaging system the proper way and will be dormant.
> Anyways, with the setting turned to "No background processes", I've
> experienced apps that still work properly. I think there must be some way to
> fix this with PhoneGap.
> This is a big deal because users should be allowed to set the option to "No
> background processes if they so desire."
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira