First some background; for the tl;dr version skip to “the problem” below.
This is really more of a user interface question than a technical one, but I think it fits better here than on the UI site anyway.
Since iOS (iPhone OS) 4.0 apps can run in the background, and actually always does so instead of quitting. Quitting an application requires pressing the home button, pressing it again, holding your finger on the application icon until it starts shaking, touching the “close” indicator, pressing the home button again. Not really intuitive.
The reason for this is of course that usually the user shouldn’t care if the app is quit or just suspended, because it doesn’t matter. But for some apps it does.
I have an app that logs location changes; think “RunKeeper” if that’s familiar. The user starts the app, chooses to start recording (to a file), or just uses it to view distance, speed, etc. When the user is done (or wants to do something else), they hit the home button. The app disappears. Now one of several things happen:
- The app quits, closing any ongoing recording (iPhoneOS 3.1.3 and below).
- The app continues running in the background, using the GPS and draining the battery (iOS 4). This is appropriate if the user for example wanted to switch to the iPod app to change their soundtrack.
- The app continues running in the background, using the GPS and draining the battery (iOS 4). This is completely inappropriate if the user was done and wanted to quit the app.
There is of course no way for the app to see the difference between cases three and four. A quick look around RunKeeper forums indicates that many users have no clue what is happening and get seriously confused by this.
So what’s the best way to solve this from a user interface point of view?
- When the home button is pressed, go into background as is the default action. It’s the user’s problem to actually kill the app if they are done. It’s the platforms fault that this is non-obvious and slightly tedious.
- When the home button is pressed and a recording is in progress, continue in background. If we are not recording, quit the application.
- Present a toggle widget somewhere in the application that allows the user to choose what happens when the home button is pressed. (This might run afoul of the HIG; I’m not sure)
What do you think?
I though to the third option without reading at it ^^ (I don’t think it would be against HIG)
So a “big” button when recording to change the “mode” ? Or a switch 😉 (Like “Continue Recording when in “background” ?”)
And maybe asking the user about it when he start registering ? (with a default value available in prefs page ?)
And as you can change songs without quitting the app, maybe setting the default value as stopping record when the app is going to background.
But I haven’t any other solution for you :-/