Thursday, February 25, 2010

Multitasking on the iPhone (a developer's view)

A common complain I hear about the iPhone is the lack of multitasking, all the other smart phones can do ti so why not the iPhone? Well it CAN do it (there are some hacks to enable it) but Apple doesn't want it enabled. Now it has some basic multitasking, you can listen to music while doing something else or even be on a call and do something else but for most applications pressing the home button means quitting. What are the pros and cons of this method?

Pros:
- Your application always has full access to the hardware (you know there's no other app in memory or using the CPU except the iPhone OS)
- The user doesn't have to worry about "closing" apps (closing vs leaving it running in the background). I remember on Windows Mobile some people would have trouble running some apps because they had to much stuff running in the background that they didn't even know about
- Applications have evolved around this "limitation" and are a lot more flexible, most apps on the iPhone will remember their last state when quitting and will bring you back exactly where you were

Cons:
- Some apps would be good candidates for multitasking, instant messaging, audio streaming apps etc. But unfortunately it would be too hard for Apple to start deciding who is allowed to multitask and who isn't
- Some apps are not as graceful in restoring the previous state and some might just start from the beginning (can be very frustrating for the end user)

Now with the iPad coming soon people are again complaining about the lack of multitasking. It would be a big deal if the iPad ran regular desktop apps (like OSX apps) but it doesn't. It will run iPhoneOS apps which have already been designed with that in mind (and the new iPad specific apps will be designed that way too).

The only problem I can see is when programmers don't work around this limitation properly. Now I'll have to admit I'm far from perfect, my own game Tangled doesn't do it properly, it will allow you to go back to the last puzzle you were on but the state is gone and you have to start over :(   . Why was it done this way? Well when I was working on Tangled I had an iPod touch and I didn't really see why people would just go out of my game and want the same state when they would come back (I figured they could just put it to sleep and come back later). Now earlier this year I finally got around getting an iPhone 3Gs and I was playing Tangled and I got a text message, so I went to reply to it and when I got back in Tangled I had to start my puzzle over! It was actually the first time I realised how frustrating it was. The first thing I did after that event was improve the way Tangled quit and resumes. The new version coming out soon will remember the exact state the game was left when it quit and will resume it properly! (plus there will be a lot more features added...see my previous post about what's coming)

Now I'm sure I'll come up with more pros and cons so I might update this post soon but in the mean time, developers and users what do you think about the lack of multitasking on the iPhone/iPad?

No comments:

Post a Comment