On Tue, Oct 22, 2013 at 11:45 AM, Rasmus Eneman <ras...@eneman.eu> wrote: > Some thoughts: > There definitely are legitimate reasons to let apps run in the background. > A game on Android I like very much is Turf, it uses the GPS to track you > when you goes around and take "zones". While playing, I usually listens > to music. And bam, a common use case where we want two apps in the > background (maybe I gets a SMS and don't change back to one of the apps > I'm "using"). > > So app definitely needs a way to run in the background and prevent sleep. > I think Android solves this very good using Activity’s and Services. An > activity is what shows the graphical interface, everything you see is an > activity. Activitys can't run in the background. Services however can't show > any graphical interface but can tun in the background. > This is good as it forces developers to write good behaving background > services (in the meaning of, it doesn't do any graphical stuff when not in > the foreground). >
Yup, we are proposing a very similar approach that dispatches tasks to services that are allowed to run in background (potentially with CPU time and/or memory being restricted). > To this Android also have a battery menu in the system settings that show > how much battery every app have been using, which makes it easy to find > out which app drained my battery. > I do disagree with requiring the user to interact with the system to ensure longer battery life. We should try as hard as possible to make this automagically work. > There are other use cases than GPS and music, apps that download stuff > for example (http, torrent, or whatever), apps that measures the > accelerometer and finds out when I'm sleeping very light. > > Personally I don't think a crippled way of running background tasks is the > best way to fix battery issues, instead let the user choose and help him > do it by displaying as much information ass possible. For a tech-savvyy audience: Yes. For everyday users I do disagree. In the end, users do blame the platform for bad battery life (for a good reason) and we certainly don't want to have battery life preserving apps in our app store (Google Play has got quite a few of them). Thanks, Thomas > Maybe there could be a setting in the battery menu "let apps run in the > background" that would make it possible for people to save as much > battery as possible if they want. > A default setting could be to disable this when the battery reaches 15% > or something. > > 2013/10/22 Alberto Mardegan <alberto.marde...@canonical.com> >> >> On 10/22/2013 09:59 AM, Thomas Voß wrote: >> > Along the same lines of the metronom app: If the gps app is in >> > foreground, the location service should signal to powerd that it >> > should not suspend at least the gps, probably the network, CPU (and >> > thus, memory access). >> >> Why does it matter if the app is in the foreground or background? A >> navigation app needs to continue runnint anyway, even if it's in the >> background. >> Shouldn't the location service also signal to the shell (or to whatever >> component is responsible for apps lifetime) that the app is using the >> GPS and shouldn't be stopped? >> >> (if not: how would you solve this use case?) >> >> Ciao, >> Alberto >> >> -- >> Mailing list: https://launchpad.net/~ubuntu-phone >> Post to : ubuntu-phone@lists.launchpad.net >> Unsubscribe : https://launchpad.net/~ubuntu-phone >> More help : https://help.launchpad.net/ListHelp > > > > > -- > Rasmus Eneman -- Mailing list: https://launchpad.net/~ubuntu-phone Post to : ubuntu-phone@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-phone More help : https://help.launchpad.net/ListHelp