Debrief : The Quick Brown Fox
I thought I’d have a bit of a debrief on my Quick Brown Fox app.
Development time was about 14 days at about 4 – 5 hours per day (~60 hours) spread over a two month period.
The project contains the following artifacts:
- Classes: 9 Controllers, 11 Views, 7 NSObject (support classes) and 2 Protocols
- Sound effects: 4
- Images: 230 flags, 110 keys, 20 others
I didn’t use the Interface Builder at all on this project.
Most of my time was spent in two areas,
- Supporting both landscape and portrait modes. This all worked fine against 2.1 SDK but broke when I upgraded to 3.0. Spent way too much time getting this to work consistently. I think the reason was that I was initially retaining views/view controllers between different tabs. So, if you swapped tabs, then rotated from landscape to portrait in the next tab, then swapped back, I had to remember what my previous orientation was and rotate that. I ended up destroying as much as possible between tabs and that improved things. Its probably how it should be done anyways w.r.t memory.
- Setting up the global high score server using Google App Engine. This was my first App Engine project so obviously there was a bit of learning to do. Also, initially got XML parsing of the results working fine in 2.1 simulator only to discover that I’d inadvertently used some Core Library classes not available on the phone, so had to rewrite all that again too. Interesting that it didn’t complain in the 2.1 simulator but did complain in the 3.0 simulator.
One other area I spent too much time on was the flashing cursor that follows where you type (in a UIWebView). This was javascript drawing on a canvas in version 1.0 but there must be some timing problem in the OS because the sentence area would flash and blank out for up to half a second every now and then. I kept getting the error: “CGImageSourceGetType image source parameter is nil” but it mostly worked. A quick search found a few other people with this problem so I needed a workaround. In version 1.1, I replaced this with a flashing image view which I move as typing occurs. Very hacky, having to define the coordinates of each position, but it only took an hour to create 2 arrays with 45 x and y coordinates, so it wasn’t too bad. Still not 100% but much better. Completely unportable obviously!
Overall, I was pretty pleased with the app, especially the moving keyboard and the global high scores.
(This blog entry was moved here from my personal site)
